/[dtapublic]/projs/trunk/shared_source/c_tk_base_7_5_w_mods/tkfilefilter.h
ViewVC logotype

Contents of /projs/trunk/shared_source/c_tk_base_7_5_w_mods/tkfilefilter.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 71 - (show annotations) (download)
Sat Nov 5 11:07:06 2016 UTC (7 years, 11 months ago) by dashley
File MIME type: text/plain
File size: 2954 byte(s)
Set EOL properties appropriately to facilitate simultaneous Linux and Windows development.
1 /* $Header$ */
2
3 /*
4 * tkFileFilter.h --
5 *
6 * Declarations for the file filter processing routines needed by
7 * the file selection dialogs.
8 *
9 * Copyright (c) 1996 Sun Microsystems, Inc.
10 *
11 * See the file "license.terms" for information on usage and redistribution
12 * of this file, and for a DISCLAIMER OF ALL WARRANTIES.
13 *
14 * RCS: @(#) $Id: tkfilefilter.h,v 1.1.1.1 2001/06/13 05:00:16 dtashley Exp $
15 *
16 */
17
18 #ifndef _TK_FILE_FILTER
19 #define _TK_FILE_FILTER
20
21 #ifdef MAC_TCL
22 #include <StandardFile.h>
23 #else
24 #define OSType long
25 #endif
26
27 #ifdef BUILD_tk
28 # undef TCL_STORAGE_CLASS
29 # define TCL_STORAGE_CLASS DLLEXPORT
30 #endif
31
32 typedef struct GlobPattern {
33 struct GlobPattern * next; /* Chains to the next glob pattern
34 * in a glob pattern list */
35 char * pattern; /* String value of the pattern, such
36 * as "*.txt" or "*.*"
37 */
38 } GlobPattern;
39
40 typedef struct MacFileType {
41 struct MacFileType * next; /* Chains to the next mac file type
42 * in a mac file type list */
43 OSType type; /* Mac file type, such as 'TEXT' or
44 * 'GIFF' */
45 } MacFileType;
46
47 typedef struct FileFilterClause {
48 struct FileFilterClause * next; /* Chains to the next clause in
49 * a clause list */
50 GlobPattern * patterns; /* Head of glob pattern type list */
51 GlobPattern * patternsTail; /* Tail of glob pattern type list */
52 MacFileType * macTypes; /* Head of mac file type list */
53 MacFileType * macTypesTail; /* Tail of mac file type list */
54 } FileFilterClause;
55
56 typedef struct FileFilter {
57 struct FileFilter * next; /* Chains to the next filter
58 * in a filter list */
59 char * name; /* Name of the file filter,
60 * such as "Text Documents" */
61 FileFilterClause * clauses; /* Head of the clauses list */
62 FileFilterClause * clausesTail; /* Tail of the clauses list */
63 } FileFilter;
64
65 /*----------------------------------------------------------------------
66 * FileFilterList --
67 *
68 * The routine TkGetFileFilters() translates the string value of the
69 * -filefilters option into a FileFilterList structure, which consists
70 * of a list of file filters.
71 *
72 * Each file filter consists of one or more clauses. Each clause has
73 * one or more glob patterns and/or one or more Mac file types
74 *----------------------------------------------------------------------
75 */
76
77 typedef struct FileFilterList {
78 FileFilter * filters; /* Head of the filter list */
79 FileFilter * filtersTail; /* Tail of the filter list */
80 int numFilters; /* number of filters in the list */
81 } FileFilterList;
82
83 extern void TkFreeFileFilters _ANSI_ARGS_((
84 FileFilterList * flistPtr));
85 extern void TkInitFileFilters _ANSI_ARGS_((
86 FileFilterList * flistPtr));
87 extern int TkGetFileFilters _ANSI_ARGS_ ((Tcl_Interp *interp,
88 FileFilterList * flistPtr, char * string,
89 int isWindows));
90
91 # undef TCL_STORAGE_CLASS
92 # define TCL_STORAGE_CLASS DLLIMPORT
93
94 #endif
95
96 /* End of tkfilefilter.h */

Properties

Name Value
svn:eol-style native
svn:keywords Header

dashley@gmail.com
ViewVC Help
Powered by ViewVC 1.1.25