1 \section{\class{wxPathList
}}\label{wxpathlist
}
3 The path list is a convenient way of storing a number of directories, and
4 when presented with a filename without a directory, searching for an existing file
5 in those directories. Storing the filename only in an application's files and
6 using a locally-defined list of directories makes the application and its files more
9 Use the
{\it wxFileNameFromPath
} global function to extract the filename
12 \wxheading{Derived from
}
14 \helpref{wxList
}{wxlist
}\\
15 \helpref{wxObject
}{wxobject
}
17 \wxheading{Include files
}
23 \helpref{wxList
}{wxlist
}
25 \latexignore{\rtfignore{\wxheading{Members
}}}
27 \membersection{wxPathList::wxPathList
}
29 \func{}{wxPathList
}{\void}
33 \membersection{wxPathList::AddEnvList
}
35 \func{void
}{AddEnvList
}{\param{const wxString\&
}{env
\_variable}}
37 Finds the value of the given environment variable, and adds all paths
38 to the path list. Useful for finding files in the PATH variable, for
41 \membersection{wxPathList::Add
}
43 \func{void
}{Add
}{\param{const wxString\&
}{path
}}
45 Adds the given directory to the path list, but does not
46 check if the path was already on the list (use wxPathList::Member)
49 \membersection{wxPathList::EnsureFileAccessible
}
51 \func{void
}{EnsureFileAccessible
}{\param{const wxString\&
}{filename
}}
53 Given a full filename (with path), ensures that files in the same path
54 can be accessed using the pathlist. It does this by stripping the
55 filename and adding the path to the list if not already there.
57 \membersection{wxPathList::FindAbsoluteValidPath
}
59 \func{wxString
}{FindAbsoluteValidPath
}{\param{const wxString\&
}{file
}}
61 Searches for a full path for an existing file by appending
{\it file
} to
62 successive members of the path list. If the file exists, a temporary
63 pointer to the absolute path is returned.
65 \membersection{wxPathList::FindValidPath
}
67 \func{wxString
}{FindValidPath
}{\param{const wxString\&
}{file
}}
69 Searches for a full path for an existing file by appending
{\it file
} to
70 successive members of the path list. If the file exists, a temporary
71 pointer to the full path is returned. This path may be relative to the current
74 \membersection{wxPathList::Member
}
76 \func{bool
}{Member
}{\param{const wxString\&
}{file
}}
78 TRUE if the path is in the path list (ignoring case).