This commit was manufactured by cvs2svn to create tag 'wxPy_2_3_4_1'.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/tags/wxPy_2_3_4_1@18324 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -24,7 +24,7 @@ Compiling wxWindows applications in the VC++ IDE
|
||||
<P>
|
||||
|
||||
<CENTER>
|
||||
<a href="#wxwin2">Settings for wxWindows 2</a> / <a href="#wxwin1">Settings for wxWindows 1.68</a>
|
||||
<a href="#wxwin2">Settings for wxWindows 2.2</a> / <a href="#wxwin1">Settings for wxWindows 1.68</a>
|
||||
</CENTER>
|
||||
|
||||
<P>
|
||||
@@ -44,9 +44,10 @@ installation path.
|
||||
|
||||
<P>
|
||||
|
||||
<H2><a name="wxwin2">Settings for wxWindows 2</a></H2>
|
||||
<H2><a name="wxwin2">Settings for wxWindows 2.2</a></H2>
|
||||
|
||||
These settings apply to wxWindows 2.1.14 and above.<P>
|
||||
These settings apply to wxWindows 2.1.14 and above but most of them are not
|
||||
necessary any longer for wxWindows 2.3+.<P>
|
||||
|
||||
<DL>
|
||||
<DT><B>General</B><DD>
|
||||
@@ -206,77 +207,6 @@ Select your .rc file. The <B>Additional resource include directories</B> field s
|
||||
|
||||
</DL>
|
||||
|
||||
<P>
|
||||
|
||||
<!--
|
||||
<PRE>
|
||||
From: "Chris Breeze" <chris@hel.co.uk>
|
||||
To: <wxwin-users@wx.dent.med.uni-muenchen.de>
|
||||
Subject: Re: Compiling 2.0 wxWin Apps in the VC IDE
|
||||
Date: Wed, 20 May 1998 14:18:02 +0100
|
||||
|
||||
First the apology: the description below is for wx1.68
|
||||
not for wx2.0 - sorry if I confused everybody.
|
||||
|
||||
Anyway, third time lucky I hope! The settings for
|
||||
VC++ 5.0, wx2.0 beta 8, NT Workstation 4.0 sp3
|
||||
are:
|
||||
|
||||
In project / settings / C/C++:
|
||||
Add "__WINDOWS__" to the pre-processor definitions
|
||||
Add "{wx}\include" to the additional include directories
|
||||
where {wx} is the directory in which wx is installed
|
||||
|
||||
In project / settings / Resources:
|
||||
add "{wx}\include" to the additional resource include directories
|
||||
|
||||
In project / settings / Link:
|
||||
Add "wx.lib comctl32.lib dummy.obj" to the Object/Library modules
|
||||
|
||||
Add "libcd.lib,libcid.lib" to ignore libraries (under the "input" category)
|
||||
|
||||
Add "{wx}\lib,{wx}\src\msw" to the additional library path
|
||||
|
||||
I have tested these settings on samples/minimal and can
|
||||
build exes which can be debugged using Developer Studio.
|
||||
|
||||
I hope I've finally answered the original question. (Next time
|
||||
I'll read the question more carefully!).
|
||||
|
||||
Regards,
|
||||
Chris
|
||||
|
||||
Original message (settings for wx1.68c):
|
||||
) Try the following (tested with VC++ 5 on NT4):
|
||||
)
|
||||
) Create a new Win32 Application project and insert the source files
|
||||
) (including .rc files).
|
||||
)
|
||||
) In project / settings / C/C++:
|
||||
) Add wx_msw to the pre-processor definitions
|
||||
) add {wx}\include\base,{wx}\include\msw to the additional include
|
||||
directories
|
||||
) where {wx} is the directory in which wx is installed
|
||||
)
|
||||
) In project / settings / Resources:
|
||||
) add {wx}\include\msw;{wx}\contrib\fafa to the additional resource include
|
||||
) directories
|
||||
)
|
||||
) In project / settings / Link:
|
||||
) Add comctl32.lib wx.lib dummy.obj ctl3d32.lib to the Object/Library modules
|
||||
)
|
||||
) Add libc to ignore libraries (under the "input" category)
|
||||
)
|
||||
) Add {wx}\lib,{wx}\src\msw to the additional library path
|
||||
)
|
||||
) These settings are for a debug build. You can use the same settings for
|
||||
) a release build apart from ignoring libc.
|
||||
|
||||
</PRE>
|
||||
-->
|
||||
|
||||
</font>
|
||||
|
||||
</BODY>
|
||||
|
||||
</HTML>
|
||||
|
@@ -13,7 +13,7 @@ the other Unix-based ports including wxMotif, wxX11 and wxBase.
|
||||
|
||||
a) Do a fresh checkout using the command
|
||||
|
||||
cvs -d :pserver:anoncvs@cvs.wxwindows.org:/home/wxcvs co wxGTK
|
||||
cvs -d :pserver:anoncvs@cvs.wxwindows.org:/packs/cvsroots/wxwindows co wxGTK
|
||||
|
||||
NB: if you realize later that some needed files were not checked out
|
||||
by this command, please modify CVSROOT/modules to include the missing
|
||||
@@ -80,7 +80,7 @@ a) Setting up the RPM tree: you should have the RPM tree set up properly
|
||||
dist").
|
||||
|
||||
b) Start RPM build by going to RPM_ROOT directory and typing "rpm -ba
|
||||
SPECS/wxGTK.spec". It may be a good idea to append "2&>1 | tee wxGTK.out"
|
||||
SPECS/wxGTK.spec". It may be a good idea to append "2>&1 | tee wxGTK.out"
|
||||
(or "|& tee" if you're using the one true shell ;-) as it might be not
|
||||
easy to detect errors in the verbose rpm output if anything goes wrong.
|
||||
|
||||
|
@@ -4,7 +4,7 @@
|
||||
!!!!! NOT YET FINISHED !!!!!
|
||||
|
||||
0. Introduction
|
||||
---------------
|
||||
===============
|
||||
|
||||
This note describes the file format used for storing XRC resources that are
|
||||
used by wxXmlResource class. It is probably only useful for those implementing
|
||||
@@ -20,31 +20,41 @@ The XRC format is based on XML 1.0 (please consult W3C's specification). There
|
||||
is no DTD available since it is not possible to fully describe the format with
|
||||
the limited expressive power of DTDs.
|
||||
|
||||
|
||||
|
||||
1. Terminology
|
||||
--------------
|
||||
==============
|
||||
|
||||
The usual XML terminology applies. In particular, we shall use the terms
|
||||
"node", "property" and "value" in the XML sense:
|
||||
NODE, PROPERTY and VALUE in the XML sense:
|
||||
|
||||
<node property1="value1" property2="value2">...</node>
|
||||
|
||||
The term "attribute" is specific to XRC and refers to a property-less subnode
|
||||
of an <object> or <object_ref> node. In the example bellow, <pos>, <label> and
|
||||
<style> are attributes, while neither <resource> nor either of <object>s is:
|
||||
The term ATTRIBUTE is specific to XRC and refers to a subnode
|
||||
of an <object> or <object_ref> node that is itself not <object> or <object_ref>.
|
||||
In the example bellow, <pos>, <label> and <style> are attributes, while neither
|
||||
<resource> nor either of <object>s is:
|
||||
|
||||
<?xml version="1.0" encoding="utf-8">
|
||||
<resource xmlns="http://www.wxwindows.org/wxxrc" version="2.3.0.1">
|
||||
<object class="wxPanel">
|
||||
<style>wxSUNKEN_BORDER</style>
|
||||
<style>wxSUNKEN_BORDER</style> <!-- attr -->
|
||||
<object class="wxStaticText">
|
||||
<label>A label</label>
|
||||
<pos>10,10</pos>
|
||||
<label>A label</label> <!-- attr -->
|
||||
<pos>10,10</pos> <!-- attr -->
|
||||
</object>
|
||||
</object>
|
||||
</resource>
|
||||
|
||||
ATTRIBUTE VALUE is the content of all text elements within attribute tag. In the
|
||||
above example, "wxSUNKEN_BORDER", "A label" and "10,10" are attribute values.
|
||||
ATTRIBUTE TYPE defines what attribute values are valid for given attribute (you
|
||||
can think of it as attribute value syntax definition).
|
||||
|
||||
|
||||
|
||||
2. Elementary description
|
||||
-------------------------
|
||||
=========================
|
||||
|
||||
XRC resource file is a well-formed XML 1.0 document. All elements of XRC file are
|
||||
from the http://www.wxwindows.org/wxxrc namespace.
|
||||
@@ -61,7 +71,7 @@ is 0 for the first incompatible change in given wxWindows release, 1 for
|
||||
the second etc.
|
||||
|
||||
Differences between versions are described within this document in paragraphs
|
||||
entitled "Version Note".
|
||||
entitled "Version Note".
|
||||
|
||||
The <resource> node contains namespace declaration, too:
|
||||
|
||||
@@ -70,20 +80,232 @@ The <resource> node contains namespace declaration, too:
|
||||
The <resource> node is only allowed to have <object> and <object_ref>
|
||||
subnodes, all of which must have the "name" property.
|
||||
|
||||
<object> - TODO (name, class, subclass)
|
||||
The <object> node represents a single object (GUI element) and it usually maps
|
||||
directly to a wxWindows class instance. It three properties: "name", "class"
|
||||
and "subclass". "class" must always be present, it tells XRC what wxWindows
|
||||
object should be created in this place. The other two are optional.
|
||||
"name" is ID used to identify the object. It is the value passed to the XRCID() macro
|
||||
and is also used to construct wxWindow's id and name attributes and must be unique
|
||||
among all children of the neareset container object (wxDialog, wxFrame, wxPanel,
|
||||
wxNotebook) upside from the object in XML nodes hiearchy (two distinct containers
|
||||
may contain objects with same "name", though). "subclass" is
|
||||
optional name of class whose constructor will be called instead of the constructor
|
||||
for "class". Subclass must be available in the program that loads the resource,
|
||||
must be derived from "class" and must be registered within wxWindows' RTTI system.
|
||||
|
||||
<object_ref> - TODO (name, ref, subclass)
|
||||
Example:
|
||||
|
||||
<object name="MyList1" class="wxListCtrl" subclass="MyListCtrlClass">
|
||||
...
|
||||
</object>
|
||||
|
||||
<object> node may have arbitrary child nodes. What child nodes and their semantics
|
||||
are class-dependent and are defined later in this document. The user is allowed
|
||||
to register new object handlers within XRC and extend it to accept new <object>
|
||||
classes (and therefore different <object>'s child nodes).
|
||||
|
||||
<object_ref> node is identical to <object>, except that it does _not_ have "class"
|
||||
property and has additonal required property "ref". It's concept is similar to Unix
|
||||
symlinks: value of the "ref" property is equal to the value of "name" property of
|
||||
some existing node (called referred node) in the resources (not neccessary top-level).
|
||||
Referred node's "class" property and all subnodes are copied in place of the referee
|
||||
<object_ref> node which is then processed as regular <object> node. If the <object_ref>
|
||||
node itself has child nodes, then these nodes _override_ any nodes from the referred node.
|
||||
|
||||
Example:
|
||||
|
||||
<object name="foo" class="wxTextCtrl">
|
||||
<value>hello</value>
|
||||
<size>100,-1d</size>
|
||||
</object>
|
||||
<object_ref name="bar" ref="foo">
|
||||
<value>bar</value> <!-- override! -->
|
||||
</object>
|
||||
|
||||
is identical to:
|
||||
|
||||
<object name="foo" class="wxTextCtrl">
|
||||
<value>hello</value>
|
||||
<size>100,-1d</size>
|
||||
</object>
|
||||
<object name="bar" class="wxTextCtrl">
|
||||
<value>bar</value>
|
||||
<size>100,-1d</size>
|
||||
</object>
|
||||
|
||||
|
||||
3. Common attributes
|
||||
--------------------
|
||||
|
||||
TODO
|
||||
3. Common attribute types
|
||||
=========================
|
||||
|
||||
There are several attribute types (see section 1. Terminology) that are common
|
||||
to many attributes of different classes:
|
||||
|
||||
String
|
||||
------
|
||||
Any text. Some characters have special interpretation and are translated
|
||||
by XRC parser according to this table:
|
||||
"_" -> "&" ('&' is used to underline e.g. menu items in wxWindows)
|
||||
"__" -> "_"
|
||||
"\n" -> line break (C character '\n')
|
||||
"\r" -> carriage return (C character '\r')
|
||||
"\t" -> tabelator (C character '\t')
|
||||
|
||||
Version Note:
|
||||
'$' was used instead of '_' prior to version 2.3.0.1.
|
||||
|
||||
|
||||
I18nString
|
||||
----------
|
||||
Like String, but the value is translated to native language using wxLocale
|
||||
at runtime (unless it was disabled by not passing wxXRC_USE_LOCALE flag to
|
||||
wxXmlResource constructor). Used for strings that are "visible" in the GUI.
|
||||
|
||||
|
||||
UnsignedInteger
|
||||
---------------
|
||||
This is obvious. Only digits 0-9 may be present and there must be at least
|
||||
one digit.
|
||||
|
||||
|
||||
Integer
|
||||
-------
|
||||
Like UnsignedInteger but may be prefixed with '-' (ints less than zero).
|
||||
|
||||
|
||||
Position
|
||||
--------
|
||||
Specifies (window's) position in 2D space. Syntax is <integer>,<integer>[d]
|
||||
where <integer> is valid value of Integer type.
|
||||
|
||||
|
||||
Size
|
||||
----
|
||||
Syntax is same as Position's syntax, but the values are interpreted as window
|
||||
size (wxSize type) and not position (wxPosition type).
|
||||
|
||||
|
||||
Style[wxSomeClass]
|
||||
------------------
|
||||
List of style flags that can be passed to wxSomeClass' constructor. Flags are
|
||||
written in same way as in C++ code (e.g. "wxSUNKEN_BORDER", "wxHW_SCROLLBAR_NEVER")
|
||||
and are delimined with any combination of whitespaces and '|'. Possible flags
|
||||
are class-dependent and are not described in this technote. Please refer to wxWindows
|
||||
manual for all styles that given class can accept; if XRC does not accept a flag
|
||||
listed in wxWindows documentation, it is a bug.
|
||||
|
||||
|
||||
Bitmap
|
||||
------
|
||||
Attribute value is interpreted as filename (either absolute or relative to
|
||||
the location of XRC resource file). In addition, attribute node may have
|
||||
"stock_id" and "stock_client" properties. Their values may be any of wxArtID (or
|
||||
wxArtClient respectively) values as used by wxArtProvider (because the user may
|
||||
define own constants, efectively any string is legal here). Examples are
|
||||
"wxART_FILE_OPEN" (id) or "wxART_MENU" (client).
|
||||
|
||||
Any of "stock_id" or "stock_client" properties or the filename may be omitted. XRC
|
||||
determines the bitmap to use according to this algorithm:
|
||||
1. If there is non-empty "stock_id" property, query wxArtProvider for the bitmap
|
||||
(if there is no "stock_client", use default one, which is usually wxART_OTHER;
|
||||
exceptions are noted in class-specific sections bellow). If the query fails,
|
||||
continue to 2.
|
||||
2. Load the bitmap from the file in attribute value.
|
||||
|
||||
|
||||
Boolean
|
||||
-------
|
||||
Boolean value, either "0" (false) or "1" (true).
|
||||
|
||||
|
||||
|
||||
4. Supported classes
|
||||
--------------------
|
||||
====================
|
||||
|
||||
Attributes are listed in tables in the following format:
|
||||
attribute name attribute type default value, if any
|
||||
[(optional remarks....................
|
||||
...................................)]
|
||||
|
||||
wxBitmap
|
||||
--------
|
||||
This is a special case, because it does not create a wxWindow instance but
|
||||
creates wxBitmap instead. Another exceptional thing is that it does not have
|
||||
any attributes. Instead, the node itself is interpreted as if it were attribute
|
||||
of type Bitmap.
|
||||
|
||||
Example: <object class="wxBitmap">bitmaps/foo.gif</object>
|
||||
|
||||
|
||||
wxIcon
|
||||
------
|
||||
Identical to wxBitmap class, except that it creates wxIcon instead of wxBitmap.
|
||||
|
||||
|
||||
wxButton
|
||||
--------
|
||||
position Position -1,-1
|
||||
size Size -1,-1
|
||||
style Style[wxButton]
|
||||
|
||||
label I18nString
|
||||
default Boolean false
|
||||
(Is the button default button?)
|
||||
|
||||
|
||||
wxCalendarCtrl
|
||||
--------------
|
||||
position Position -1,-1
|
||||
size Size -1,-1
|
||||
style Style[wxCalendarCtrl]
|
||||
|
||||
|
||||
wxCheckBox
|
||||
----------
|
||||
position Position -1,-1
|
||||
size Size -1,-1
|
||||
style Style[wxCheckBox]
|
||||
checked Boolean false
|
||||
|
||||
|
||||
wxCheckList
|
||||
-----------
|
||||
position Position -1,-1
|
||||
size Size -1,-1
|
||||
style Style[wxCheckList]
|
||||
content (see bellow) (empty)
|
||||
|
||||
Optional "content" attribute does not have attribute value. Instead,
|
||||
arbitrary number of <item> nodes may be rooted under it (the control
|
||||
is filled with strings contained in these nodes). Each <item>
|
||||
node must contain I18nString value and may have "checked" property
|
||||
with possible values "0" or "1" indicating the the item is initially
|
||||
checked.
|
||||
|
||||
Example:
|
||||
<object class="wxCheckList">
|
||||
<content>
|
||||
<item>One</item>
|
||||
<item checked="1">Two</item>
|
||||
<item checked="1">Three</item>
|
||||
<item>Four</item>
|
||||
</content>
|
||||
</object>
|
||||
|
||||
|
||||
wxScrolledWindow
|
||||
----------------
|
||||
position Position -1,-1
|
||||
size Size -1,-1
|
||||
style Style[wxScrolledWindow] wxHSCROLL | wxVSCROLL
|
||||
|
||||
|
||||
|
||||
5. More features
|
||||
================
|
||||
|
||||
FIXME -- "platform" property handling
|
||||
|
||||
TODO
|
||||
|
||||
=== EOF ===
|
||||
|
||||
|
Reference in New Issue
Block a user