wnd-commit Mailing List for wnd
Status: Alpha
Brought to you by:
jurner
You can subscribe to this list here.
2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(125) |
Jun
|
Jul
(138) |
Aug
(13) |
Sep
|
Oct
|
Nov
|
Dec
|
---|---|---|---|---|---|---|---|---|---|---|---|---|
2008 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(1) |
From: jürgen u. <cer...@us...> - 2005-08-14 18:18:22
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/gdip/Image In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28072 Modified Files: image.dtpl Log Message: combing over Index: image.dtpl =================================================================== RCS file: /cvsroot/wnd/wnd/wnd_doc/doc/gdip/Image/image.dtpl,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** image.dtpl 14 Aug 2005 15:55:58 -0000 1.2 --- image.dtpl 14 Aug 2005 18:18:15 -0000 1.3 *************** *** 9,13 **** writing ! <b>BMP, GIF, JPEG, PNG, TIFF, ICO, EMF (reading), WNF (reading)<b> <br><br> If you are curious take loook at --- 9,13 ---- writing ! <b>BMP, GIF, JPEG, PNG, TIFF, ICO, EMF (reading), WNF (reading)</b> <br><br> If you are curious take loook at *************** *** 25,28 **** --- 25,83 ---- + ::site:: class BitmapFromFile + <code class=import>defined in: wnd.gdip</code><br><br> + <code> BitmapFromFile(path)</code><br> + <P>Loads an image from file + The file may contain one of the following image formats: + <br><br> + By default gdi-plus supports the folloeing image firmats for reading and + writing + + <b>BMP, GIF, JPEG, PNG, TIFF, ICO, EMF (reading), WNF (reading)</b> + <br><br> + If you are curious take loook at + 'HKEY_CLASSES_ROOT\MIME\Database\Content Type\image/*' + to see what image filters are registered (ImageEn/Decoder does the same). + 'ImageFilter CLSID' is the CLSID of an image filter registered + for the image type. + <br><br> + </P> + + + + ::folder:: Bitmap methods + Bitmap instances support the following methods: + <br> + <a HREGF="../Image methods/contents.html">Image methods</a> + + ::item:: GetHBITMAP + <code>GetHBITMAP()</code><br> + <P>Creates a GDI bitmap handle from the bitmap. + </P> + + ::item:: GetHICON + <code>GetHICON()</code><br> + <P>Creates a GDI icon handle from the bitmap. + </P> + + ::item:: CloneL + <code>CloneL(x, y, w, h, pixel_format)</code><br> + <P>Extracts a portion (or all) of the bitmap and returns it a new bitmap + according to the pixeö_mode specified. + <br><br> + See ||type-PixelFormats|| + </P> + + ::item:: Clone + <code>Clone(x, y, w, h, pixel_format)</code><br> + <P>Extracts a portion (or all) of the bitmap and returns it a new bitmap + according to the pixeö_mode specified. + The dimensions of the area to clone may be specified as float values + <br><br> + See ||type-PixelFormats|| + </P> + + + ::folder:: Image methods Image instances support the following methods *************** *** 66,69 **** --- 121,146 ---- is not stored in the image). </P> + + ::item:: SetPalette + <code>SetPalette()</code><br> + <P>Sets ColorPalette for the image. palette should be a ||type-ColorPalette|| + with 'Count' set to the number of colors used. This should be 2 for 1-bit + images, 16 for 4-bit and 256 for 8-bit images. Images with a higher resolution + then 8-bits do not use a palette + </P> + + + ::item:: GetFormat + <code>GetFormat()</code><br> + <P>Returns a GUID describing the format of the image. + You can compare the returned GUID to one of the + ||type-ImageFormats|| to find out the actual format of the image + </P> + + ::item:: RotateFlip + <code>RotateFlip(rfType)</code><br> + <P>Rotates and/or flips the image. See ||type-RoptateFlip|| constants for + the rfType argument describing how to flip or rotate the image. + </P> *************** *** 71,78 **** <code>SaveToFile(path, Encoder)</code><br> <P>Saves the image to file. Encoder should be an encoder ! returned by the 'ImageCodec.getEncoder' method. </P> ::item:: Close <code>Close()</code><br> --- 148,156 ---- <code>SaveToFile(path, Encoder)</code><br> <P>Saves the image to file. Encoder should be an encoder ! returned by the 'ImageEncoder' (no link yet) class. </P> + ::item:: Close <code>Close()</code><br> |
From: jürgen u. <cer...@us...> - 2005-08-14 18:18:15
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/gdip In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28025/wnd_doc/doc/gdip Modified Files: gdip.dtpl Log Message: combing over Index: gdip.dtpl =================================================================== RCS file: /cvsroot/wnd/wnd/wnd_doc/doc/gdip/gdip.dtpl,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** gdip.dtpl 14 Aug 2005 15:55:46 -0000 1.2 --- gdip.dtpl 14 Aug 2005 18:18:06 -0000 1.3 *************** *** 26,32 **** <a HREF="::root::gdip/Structures, types and makros/ImageFlags.html">ImageFlags</a> ! ::def:: ||type-IColorPalette|| <a HREF="::root::gdip/Structures, types and makros/ColorPalette.html">ColorPalette</a> ! C ::site:: gdip --- 26,42 ---- <a HREF="::root::gdip/Structures, types and makros/ImageFlags.html">ImageFlags</a> ! ::def:: ||type-ColorPalette|| <a HREF="::root::gdip/Structures, types and makros/ColorPalette.html">ColorPalette</a> ! ! ::def:: ||type-ImageFormat|| ! <a HREF="::root::gdip/Structures, types and makros/ImageFormats.html">ImageFormats</a> ! ! ::def:: ||type-RoptateFlip|| ! <a HREF="::root::gdip/Structures, types and makros/RotateFlip.html">RotateFlip</a> ! ! ::def:: ||type-PixelFormats|| ! <a HREF="::root::gdip/Structures, types and makros/PixelFormats.html">PixelFormats</a> ! ! ::site:: gdip *************** *** 54,424 **** - ::folder:: tructures, types and makros - - ::site:: ColorPalette - - <code class=import>defined in: wnd.gdip</code><br><br> - Structure used with palettes<br> - - <P> - <strong>Members:</strong><br> - <DL> - <DT>Flags - <DD>palette flags (currently not used) - <DT>Count - <DD>number of entries in the palete - <DT>Entries - <DD>an array of Count size length containing the ARGB color values - </DL> - <br><br> - - - - ::site:: Units - <TABLE class="table1" BORDER="1"> - <TR> - <TD>UnitWorld</TD> - <TD>World coordinate (non-physical unit)</TD> - </TR> - <TR> - <TD>UnitDisplay</TD> - <TD>Variable -- for PageTransform only</TD> - </TR> - <TR> - <TD>UnitPixel</TD> - <TD>Each unit is one device pixel.</TD> - </TR> - <TR> - <TD>UnitPoint</TD> - <TD>Each unit is a printer's point, or 1/72 inch.</TD> - </TR> - <TR> - <TD>UnitInch</TD> - <TD>Each unit is 1 inch.</TD> - </TR> - <TR> - <TD>UnitDocument</TD> - <TD>Each unit is 1/300 inch.</TD> - </TR> - <TR> - <TD>UnitMillimeter</TD> - <TD>Each unit is 1 millimeter.</TD> - </TR> - </TABLE> - - - ::site:: Linecaps - <TABLE class="table1" BORDER="1"> - <TR> - <TD>LineCapFlat</TD> - <TD></TD> - </TR> - <TR> - <TD>LineCapSquare</TD> - <TD></TD> - </TR> - <TR> - <TD>LineCapRound</TD> - <TD></TD> - </TR> - <TR> - <TD>LineCapNoAnchor </TD> - <TD>corresponds to flat cap</TD> - </TR> - <TR> - <TD>LineCapSquareAnchor </TD> - <TD>orresponds to square cap</TD> - </TR> - <TR> - <TD>LineCapRoundAnchor</TD> - <TD>corresponds to round cap</TD> - </TR> - <TR> - <TD>LineCapDiamondAnchor</TD> - <TD>corresponds to triangle cap</TD> - </TR> - <TR> - <TD>LineCapArrowAnchor</TD> - <TD>no correspondence</TD> - </TR> - <TR> - <TD>LineCapCustom</TD> - <TD>custom cap</TD> - </TR> - <TR> - <TD>LineCapAnchorMask</TD> - <TD>mask to check for anchor or not. </TD> - </TR> - </TABLE> - - - ::site:: Dashstyles - <TABLE class="table1" BORDER="1"> - <TR> - <TD>DashStyleSolid</TD> - <TD></TD> - </TR> - <TR> - <TD>DashStyleDash</TD> - <TD></TD> - </TR> - <TR> - <TD>DashStyleDashDot</TD> - <TD></TD> - </TR> - <TR> - <TD>DashStyleDashDotDot</TD> - <TD></TD> - </TR> - <TR> - <TD>DashStyleCustom</TD> - <TD></TD> - </TR> - </TABLE> - - - ::site:: Dashcaps - <TABLE class="table1" BORDER="1"> - <TR> - <TD>DashCapFlat</TD> - <TD></TD> - </TR> - <TR> - <TD>DashCapRound</TD> - <TD></TD> - </TR> - <TR> - <TD>DashCapTriangle</TD> - <TD></TD> - </TR> - </TABLE> - - - ::site:: Linejoins - <TABLE class="table1" BORDER="1"> - <TR> - <TD>LineJoinMiter</TD> - <TD></TD> - </TR> - <TR> - <TD>LineJoinBevel </TD> - <TD></TD> - </TR> - <TR> - <TD>LineJoinMiterClipped</TD> - <TD></TD> - </TR> - </TABLE> - - - ::site:: ImageFlags - <TABLE class="table1" BORDER="1"> - <TR> - <TD>ImageFlagsNone</TD> - <TD></TD> - </TR> - <TR> - <TD>ImageFlagsScalable</TD> - <TD></TD> - </TR> - <TR> - <TD>ImageFlagsHasAlpha</TD> - <TD></TD> - </TR> - <TR> - <TD>ImageFlagsHasTranslucent</TD> - <TD></TD> - </TR> - <TR> - <TD>ImageFlagsPartiallyScalable</TD> - <TD></TD> - </TR> - <TR> - <TD>ImageFlagsColorSpaceRGB</TD> - <TD></TD> - </TR> - <TR> - <TD>ImageFlagsColorSpaceCMYK</TD> - <TD></TD> - </TR> - <TR> - <TD>ImageFlagsColorSpaceGRAY</TD> - <TD></TD> - </TR> - <TR> - <TD>ImageFlagsColorSpaceYCBCR</TD> - <TD></TD> - </TR> - <TR> - <TD>ImageFlagsHasRealDPI</TD> - <TD></TD> - </TR> - <TR> - <TD>ImageFlagsHasRealPixelSize</TD> - <TD></TD> - </TR> - <TR> - <TD>ImageFlagsReadOnly</TD> - <TD></TD> - </TR> - <TR> - <TD>ImageFlagsCaching</TD> - <TD></TD> - </TR> - </TABLE> - - ::site:: Foo - <TABLE class="table1" BORDER="1"> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD>/TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - </TABLE> - - - - - - - ::site:: Foo - <TABLE class="table1" BORDER="1"> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD>/TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - </TABLE> - - - - - - ::site:: Foo - <TABLE class="table1" BORDER="1"> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD>/TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - <TR> - <TD></TD> - <TD></TD> - </TR> - </TABLE> - - - - - - - - - - - - --- 64,68 ---- |
From: jürgen u. <cer...@us...> - 2005-08-14 18:18:14
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/gdip/color In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28025/wnd_doc/doc/gdip/color Modified Files: color.dtpl Log Message: combing over Index: color.dtpl =================================================================== RCS file: /cvsroot/wnd/wnd/wnd_doc/doc/gdip/color/color.dtpl,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** color.dtpl 29 Apr 2005 15:15:37 -0000 1.1.1.1 --- color.dtpl 14 Aug 2005 18:18:06 -0000 1.2 *************** *** 43,48 **** </P> ! ::item:: ToCOLORREF(self) ! <code>ToCOLORREF(self)</code><br> <P>Converts the ARGB value of the color into a ||type-COLORREF|| value </P> --- 43,48 ---- </P> ! ::item:: ToCOLORREF ! <code>ToCOLORREF()</code><br> <P>Converts the ARGB value of the color into a ||type-COLORREF|| value </P> |
From: jürgen u. <cer...@us...> - 2005-08-14 18:18:14
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/gdip/ImageCodec In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28025/wnd_doc/doc/gdip/ImageCodec Modified Files: imagecodec.dtpl Log Message: combing over Index: imagecodec.dtpl =================================================================== RCS file: /cvsroot/wnd/wnd/wnd_doc/doc/gdip/ImageCodec/imagecodec.dtpl,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** imagecodec.dtpl 14 Aug 2005 15:55:47 -0000 1.1 --- imagecodec.dtpl 14 Aug 2005 18:18:05 -0000 1.2 *************** *** 7,10 **** --- 7,11 ---- <P> Initializes a class for handling image encoders + You use this class to iterate over all image decoders currently available on the system. <P> *************** *** 15,59 **** <P> Initializes a class for handling image encoders - - - The class contains the following constants to interpret - the Flags member of a ||type-ImageCodecInfo|| structure: <br><br> ! ! <TABLE class="table1" BORDER="1"> ! <TR> ! <TD>SupportBitmap</TD> ! <TD>the codec supports bitmaps</TD> ! <TR> ! <TR> ! <TD>BlockingDecode</TD> ! <TD>indicates that the codec blocks during decoding</TD> ! <TR> ! <TR> ! <TD>Builtin</TD> ! <TD>the codec is gdi+ builtin</TD> ! <TR> ! <TR> ! <TD>Decoder</TD> ! <TD>the codec supports decoding</TD> ! <TR> ! <TR> ! <TD>Encoder</TD> ! <TD>the codec supports encoding</TD> ! <TR> ! <TR> ! <TD>SeekableEncode</TD> ! <TD>indicates that the codec requires a seekable output stream</TD> ! <TR> ! <TR> ! <TD>SupportVector</TD> ! <TD>the codec supports vector images</TD> ! <TR> ! </TABLE> ! ! <br><br> ! You would use this class to iterate over all image encoders currently available on the system. ! ! </P> --- 16,21 ---- <P> Initializes a class for handling image encoders <br><br> ! You use this class to iterate over all image encoders currently available on the system. </P> *************** *** 65,73 **** ::item:: __iter__ <code>__iter__()</code><br> ! <P>Iterates over all available image encoders returning the next ||type-ImageCodecInfo|| in turn, describing an image encoder. </P> ! ::item:: GetCodecSignature <code>GetCodecSignature(Encoder)</code><br> --- 27,70 ---- ::item:: __iter__ <code>__iter__()</code><br> ! <P>Iterates over all available image de/encoders returning the next ||type-ImageCodecInfo|| in turn, describing an image encoder. </P> ! ::item:: IsEncoder ! <code>IsEncoder()</code><br> ! <P>Returns True if the codec supports encoding, False otherwise ! </P> ! ! ::item:: IsDecoder ! <code>IsEncoder()</code><br> ! <P>Returns True if the codec supports decoding, False otherwise ! </P> ! ! ::item:: SuportsBitmap ! <code>SuportsBitmap()</code><br> ! <P>Returns True if the codec supports bitmaps, False otherwise ! </P> ! ! ::item:: SuportsVector ! <code>SuportsBitmap()</code><br> ! <P>Returns True if the codec supports vector graphics, False otherwise ! </P> ! ! ::item:: NeedsSeekableEncode ! <code>NeedsSeekableEncode()</code><br> ! <P>Returns True if the codec requires a seekable output stream, False otherwise ! </P> ! ! ::item:: NeedsBlockingDecode ! <code>NeedsBlockingDecode()</code><br> ! <P>Returns True if the codec is blocking during decoding, False otherwise ! </P> ! ! ::item:: IsBuiltin ! <code> IsBuiltin()</code><br> ! <P>Returns True if the codec is (gdi-plus) builtin, False otherwise ! </P> ! ! ::item:: GetCodecSignature <code>GetCodecSignature(Encoder)</code><br> |
From: jürgen u. <cer...@us...> - 2005-08-14 18:16:50
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/gdip/Structures, types and makros In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv27652/wnd_doc/doc/gdip/Structures, types and makros Modified Files: Structures, types and makros.dtpl Log Message: Index: Structures, types and makros.dtpl =================================================================== RCS file: /cvsroot/wnd/wnd/wnd_doc/doc/gdip/Structures, types and makros/Structures, types and makros.dtpl,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** Structures, types and makros.dtpl 29 Apr 2005 15:15:32 -0000 1.1.1.1 --- Structures, types and makros.dtpl 14 Aug 2005 18:16:41 -0000 1.2 *************** *** 1,61 **** - ::site:: structures, types and makros - doc here ! ::site:: units ! The gdip module defines the following unit constants: ! <br><br> <TABLE class="table1" BORDER="1"> <TR> ! <TD>UnitDisplay</TD> ! <TD>Variable -- for PageTransform only</TD> </TR> <TR> ! <TD>UnitDocument</TD> ! <TD>Each unit is 1/300 inch.</TD> </TR> <TR> ! <TD>UnitInch</TD> ! <TD>Each unit is 1 inch.</TD> </TR> <TR> ! <TD>UnitMillimeter</TD> ! <TD>Each unit is 1 millimeter.</TD> </TR> <TR> ! <TD>UnitPixel</TD> ! <TD>ach unit is one device pixel</TD> </TR> <TR> ! <TD>UnitPoint</TD> ! <TD>Each unit is a printer's point, or 1/72 inch</TD> </TR> <TR> ! <TD>UnitWorld</TD> ! <TD>World coordinate (non-physical unit)</TD> </TR> </TABLE> ! ! ::site:: linecaps <TABLE class="table1" BORDER="1"> <TR> <TD>LineCapFlat</TD> ! <TD>flat line cap</TD> </TR> <TR> <TD>LineCapSquare</TD> ! <TD>square line cap</TD> </TR> <TR> <TD>LineCapRound</TD> ! <TD>round line cap</TD> ! </TR> ! <TR> ! <TD>LineCapTriangle </TD> ! <TD>triangle line cap</TD> </TR> <TR> --- 1,52 ---- ! ::site:: Units <TABLE class="table1" BORDER="1"> <TR> ! <TD>UnitWorld</TD> ! <TD>World coordinate (non-physical unit)</TD> </TR> <TR> ! <TD>UnitDisplay</TD> ! <TD>Variable -- for PageTransform only</TD> </TR> <TR> ! <TD>UnitPixel</TD> ! <TD>Each unit is one device pixel.</TD> </TR> <TR> ! <TD>UnitPoint</TD> ! <TD>Each unit is a printer's point, or 1/72 inch.</TD> </TR> <TR> ! <TD>UnitInch</TD> ! <TD>Each unit is 1 inch.</TD> </TR> <TR> ! <TD>UnitDocument</TD> ! <TD>Each unit is 1/300 inch.</TD> </TR> <TR> ! <TD>UnitMillimeter</TD> ! <TD>Each unit is 1 millimeter.</TD> </TR> </TABLE> ! ::site:: Linecaps <TABLE class="table1" BORDER="1"> <TR> <TD>LineCapFlat</TD> ! <TD></TD> </TR> <TR> <TD>LineCapSquare</TD> ! <TD></TD> </TR> <TR> <TD>LineCapRound</TD> ! <TD></TD> </TR> <TR> *************** *** 64,69 **** </TR> <TR> ! <TD>LineCapSquareAnchor</TD> ! <TD>corresponds to square cap</TD> </TR> <TR> --- 55,60 ---- </TR> <TR> ! <TD>LineCapSquareAnchor </TD> ! <TD>orresponds to square cap</TD> </TR> <TR> *************** *** 77,94 **** <TR> <TD>LineCapArrowAnchor</TD> ! <TD></TD> </TR> <TR> <TD>LineCapCustom</TD> ! <TD></TD> </TR> <TR> <TD>LineCapAnchorMask</TD> <TD></TD> </TR> </TABLE> - ! ::site:: dashcaps <TABLE class="table1" BORDER="1"> <TR> --- 68,110 ---- <TR> <TD>LineCapArrowAnchor</TD> ! <TD>no correspondence</TD> </TR> <TR> <TD>LineCapCustom</TD> ! <TD>custom cap</TD> </TR> <TR> <TD>LineCapAnchorMask</TD> + <TD>mask to check for anchor or not. </TD> + </TR> + </TABLE> + + + ::site:: Dashstyles + <TABLE class="table1" BORDER="1"> + <TR> + <TD>DashStyleSolid</TD> + <TD></TD> + </TR> + <TR> + <TD>DashStyleDash</TD> + <TD></TD> + </TR> + <TR> + <TD>DashStyleDashDot</TD> + <TD></TD> + </TR> + <TR> + <TD>DashStyleDashDotDot</TD> + <TD></TD> + </TR> + <TR> + <TD>DashStyleCustom</TD> <TD></TD> </TR> </TABLE> ! ! ::site:: Dashcaps <TABLE class="table1" BORDER="1"> <TR> *************** *** 96,104 **** <TD></TD> </TR> ! <TR> <TD>DashCapRound</TD> <TD></TD> </TR> ! <TR> <TD>DashCapTriangle</TD> <TD></TD> --- 112,120 ---- <TD></TD> </TR> ! <TR> <TD>DashCapRound</TD> <TD></TD> </TR> ! <TR> <TD>DashCapTriangle</TD> <TD></TD> *************** *** 107,135 **** ! ::site:: dashstyles <TABLE class="table1" BORDER="1"> <TR> ! <TD>DashStyleSolid</TD> <TD></TD> </TR> ! <TR> ! <TD>DashStyleDash</TD> <TD></TD> </TR> ! <TR> ! <TD>DashStyleDot</TD> <TD></TD> </TR> <TR> ! <TD>DashStyleDashDot</TD> <TD></TD> </TR> ! <TR> ! <TD>DashStyleDashDotDot</TD> <TD></TD> </TR> ! <TR> ! <TD>DashStyleCustom</TD> <TD></TD> </TR> --- 123,195 ---- ! ::site:: Linejoins ! <TABLE class="table1" BORDER="1"> ! <TR> ! <TD>LineJoinMiter</TD> ! <TD></TD> ! </TR> ! <TR> ! <TD>LineJoinBevel </TD> ! <TD></TD> ! </TR> ! <TR> ! <TD>LineJoinMiterClipped</TD> ! <TD></TD> ! </TR> ! </TABLE> + + ::site:: ImageFlags <TABLE class="table1" BORDER="1"> <TR> ! <TD>ImageFlagsNone</TD> <TD></TD> </TR> ! <TR> ! <TD>ImageFlagsScalable</TD> <TD></TD> </TR> ! <TR> ! <TD>ImageFlagsHasAlpha</TD> <TD></TD> </TR> <TR> ! <TD>ImageFlagsHasTranslucent</TD> <TD></TD> </TR> ! <TR> ! <TD>ImageFlagsPartiallyScalable</TD> <TD></TD> </TR> ! <TR> ! <TD>ImageFlagsColorSpaceRGB</TD> ! <TD></TD> ! </TR> ! <TR> ! <TD>ImageFlagsColorSpaceCMYK</TD> ! <TD></TD> ! </TR> ! <TR> ! <TD>ImageFlagsColorSpaceGRAY</TD> ! <TD></TD> ! </TR> ! <TR> ! <TD>ImageFlagsColorSpaceYCBCR</TD> ! <TD></TD> ! </TR> ! <TR> ! <TD>ImageFlagsHasRealDPI</TD> ! <TD></TD> ! </TR> ! <TR> ! <TD>ImageFlagsHasRealPixelSize</TD> ! <TD></TD> ! </TR> ! <TR> ! <TD>ImageFlagsReadOnly</TD> ! <TD></TD> ! </TR> ! <TR> ! <TD>ImageFlagsCaching</TD> <TD></TD> </TR> *************** *** 137,156 **** ! ::site:: linejoin <TABLE class="table1" BORDER="1"> <TR> ! <TD>LineJoinMiter</TD> <TD></TD> </TR> <TR> ! <TD>LineJoinBevel</TD> <TD></TD> </TR> <TR> ! <TD>LineJoinRound</TD> <TD></TD> </TR> <TR> ! <TD>LineJoinMiterClipped</TD> <TD></TD> </TR> --- 197,243 ---- ! ::site:: ImageFormats ! ! GUIDs of image formats ! <TABLE class="table1" BORDER="1"> <TR> ! <TD>ImageFormatUndefined</TD> <TD></TD> </TR> <TR> ! <TD>ImageFormatMemoryBMP</TD> <TD></TD> </TR> <TR> ! <TD>ImageFormatBMP</TD> <TD></TD> </TR> <TR> ! <TD>ImageFormatEMF</TD> ! <TD></TD> ! </TR> ! <TR> ! <TD>ImageFormatWMF</TD> ! <TD></TD> ! </TR> ! <TR> ! <TD>ImageFormatJPEG</TD> ! <TD></TD> ! </TR> ! <TR> ! <TD>ImageFormatPNG</TD> ! <TD></TD> ! </TR> ! <TR> ! <TD>ImageFormatGIF</TD> ! <TD></TD> ! </TR> ! <TR> ! <TD>ImageFormatEXIF</TD> ! <TD></TD> ! </TR> ! <TR> ! <TD>ImageFormatIcon</TD> <TD></TD> </TR> *************** *** 158,164 **** ::site:: ImageCodecInfo ! <code class=import>defined in: wnd.gdip.wintypes</code><br><br> Structure describing an image codec<br> --- 245,606 ---- + ::site:: PixelFormats + <TABLE class="table1" BORDER="1"> + <TR> + <TD>PixelFormat1bppIndexed</TD> + <TD>1 bit, indexed</TD> + </TR> + <TR> + <TD>PixelFormat4bppIndexed</TD> + <TD>4 bits, indexed</TD> + </TR> + <TR> + <TD>PixelFormat8bppIndexed</TD> + <TD>8 bits, index4ed</TD> + </TR> + <TR> + <TD>PixelFormat16bppGrayScale</TD> + <TD>16 bit grayscale</TD> + </TR> + <TR> + <TD>PixelFormat16bppRGB555</TD> + <TD>16 bits, 5 bits each are used for the red, green, and blue + components. The remaining bit is not used</TD> + </TR> + <TR> + <TD>PixelFormat16bppRGB565</TD> + <TD>16 bits, 5 bits are used for the red component, 6 bits are used for the + green component, and 5 bits are used for the blue component. + </TD> + </TR> + <TR> + <TD>PixelFormat16bppARGB1555</TD> + <TD></TD> + </TR> + <TR> + <TD>PixelFormat24bppRGB</TD> + <TD>24 bits</TD> + </TR> + <TR> + <TD>PixelFormat32bppRGB</TD> + <TD>32 bits</TD> + </TR> + <TR> + <TD>PixelFormat32bppARGB</TD> + <TD>32 bits</TD> + </TR> + <TR> + <TD>PixelFormat32bppPARGB</TD> + <TD>32 bits</TD> + </TR> + <TR> + <TD>PixelFormat64bppPARGB</TD> + <TD>64 bits</TD> + </TR> + <TR> + <TD>PixelFormatMax</TD> + <TD>maximum number of pixel formats supported</TD> + </TR> + + </TABLE> + + + + + + ::site:: Foo + <TABLE class="table1" BORDER="1"> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD>/TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + </TABLE> + + + + ::site:: RotateFlip + <TABLE class="table1" BORDER="1"> + <TR> + <TD> RotateNoneFlipNone</TD> + <TD></TD> + </TR> + <TR> + <TD>Rotate90FlipNone</TD> + <TD></TD> + </TR> + <TR> + <TD>Rotate180FlipNone</TD> + <TD></TD> + </TR> + <TR> + <TD>Rotate270FlipNone</TD> + <TD></TD> + </TR> + <TR> + <TD>RotateNoneFlipX</TD> + <TD></TD> + </TR> + <TR> + <TD>Rotate90FlipX</TD> + <TD></TD> + </TR> + <TR> + <TD> Rotate180FlipX</TD> + <TD></TD> + </TR> + <TR> + <TD> Rotate270FlipX</TD> + <TD></TD> + </TR> + <TR> + <TD>RotateNoneFlipY</TD> + <TD></TD> + </TR> + <TR> + <TD>Rotate90FlipY</TD> + <TD></TD> + </TR> + <TR> + <TD>Rotate180FlipY</TD> + <TD></TD> + </TR> + <TR> + <TD>Rotate270FlipY</TD> + <TD></TD> + </TR> + <TR> + <TD>RotateNoneFlipXY</TD> + <TD></TD> + </TR> + <TR> + <TD>Rotate90FlipXY</TD> + <TD></TD> + </TR> + <TR> + <TD>Rotate180FlipXY</TD> + <TD></TD> + </TR> + <TR> + <TD>Rotate270FlipXY</TD> + <TD></TD> + </TR> + </TABLE> + + + + ::site:: Foo + <TABLE class="table1" BORDER="1"> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD>/TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + </TABLE> + + + + ::site:: Foo + <TABLE class="table1" BORDER="1"> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD>/TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + </TABLE> + + + + ::site:: Foo + <TABLE class="table1" BORDER="1"> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD>/TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + </TABLE> + + + + + + + + + + + + + + + + + + + + + + + + ::site:: ColorPalette + + <code class=import>defined in: wnd.gdip</code><br><br> + Structure used with palettes<br> + + <P> + <strong>Members:</strong><br> + <DL> + <DT>Flags + <DD>palette flags (currently not used) + <DT>Count + <DD>number of entries in the palete + <DT>Entries + <DD>an array of Count size length containing the ARGB color values + </DL> + <br><br> + ::site:: ImageCodecInfo ! <code class=import>defined in: wnd.gdip.wintypes</code><br><br> Structure describing an image codec<br> *************** *** 200,202 **** structures define a method to extract the arrays from the structure. - \ No newline at end of file --- 642,643 ---- |
From: jürgen u. <cer...@us...> - 2005-08-14 18:16:50
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/gdip/Structures, types and makros/Color In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv27652/wnd_doc/doc/gdip/Structures, types and makros/Color Removed Files: .CVSIGNORE Color.dtpl Log Message: --- .CVSIGNORE DELETED --- --- Color.dtpl DELETED --- |
From: jürgen u. <cer...@us...> - 2005-08-14 15:58:12
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/gdip/ImageEncoder In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31767/wnd_doc/doc/gdip/ImageEncoder Removed Files: .CVSIGNORE Log Message: --- .CVSIGNORE DELETED --- |
From: jürgen u. <cer...@us...> - 2005-08-14 15:56:14
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/gdip/Image In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31467 Modified Files: image.dtpl Log Message: comb over Index: image.dtpl =================================================================== RCS file: /cvsroot/wnd/wnd/wnd_doc/doc/gdip/Image/image.dtpl,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** image.dtpl 29 Apr 2005 15:15:38 -0000 1.1.1.1 --- image.dtpl 14 Aug 2005 15:55:58 -0000 1.2 *************** *** 1,2 **** --- 1,3 ---- + ::site:: class ImageFromFile <code class=import>defined in: wnd.gdip</code><br><br> *************** *** 4,9 **** <P>Loads an image from file The file may contain one of the following image formats: ! <br> ! BMP, GIF, JPEG, PNG, TIFF, and EMF </P> --- 5,25 ---- <P>Loads an image from file The file may contain one of the following image formats: ! <br><br> ! By default gdi-plus supports the folloeing image firmats for reading and ! writing ! ! <b>BMP, GIF, JPEG, PNG, TIFF, ICO, EMF (reading), WNF (reading)<b> ! <br><br> ! If you are curious take loook at ! 'HKEY_CLASSES_ROOT\MIME\Database\Content Type\image/*' ! to see what image filters are registered (ImageEn/Decoder does the same). ! 'ImageFilter CLSID' is the CLSID of an image filter registered ! for the image type. ! </P> ! ! ::site:: class ImageFromStream ! <code class=import>defined in: wnd.gdip</code><br><br> ! <code> ImageFromStream(stream)</code><br> ! <P>Loads an image from a stream </P> *************** *** 34,40 **** </P> ! ::item:: SaveToFile ! <code>SaveToFile(path, Encoder, overwrite=False)</code><br> <P>Saves the image to file. Encoder should be an encoder returned by the 'ImageCodec.getEncoder' method. --- 50,73 ---- </P> ! ::item:: GetFlags ! <code>GetFlags()</code><br> ! <P>Returns an integer holding a set of bitflags. See ||type-ImageFlags|| for details ! </P> ! ! ::item:: GetSize ! <code>GetSize()</code><br> ! <P>Returns tuple(w, h) containing the size of the image ! </P> ! ! ::item:: GetPalette ! <code>GetPalette()</code><br> ! <P>Returns a ColorPalette structure containing the ||type-ColorPalette|| used by the image. the <b>nEntries</b> member of the retuned ! structure should always be zero for images > 8bpp (the palette ! is not stored in the image). ! </P> ! ! ::item:: SaveToFile ! <code>SaveToFile(path, Encoder)</code><br> <P>Saves the image to file. Encoder should be an encoder returned by the 'ImageCodec.getEncoder' method. |
From: jürgen u. <cer...@us...> - 2005-08-14 15:56:02
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/gdip In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31420/wnd_doc/doc/gdip Modified Files: gdip.dtpl Log Message: comb over Index: gdip.dtpl =================================================================== RCS file: /cvsroot/wnd/wnd/wnd_doc/doc/gdip/gdip.dtpl,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** gdip.dtpl 29 Apr 2005 15:15:30 -0000 1.1.1.1 --- gdip.dtpl 14 Aug 2005 15:55:46 -0000 1.2 *************** *** 5,26 **** ::def:: ||type-unit|| ! <a HREF="::root::gdip/Structures, types and makros/units.html.html">unit</a> ::def:: ||type-linecap|| ! <a HREF="::root::gdip/Structures, types and makros/linecap.html.html">linecap</a> ::def:: ||type-dashcap|| ! <a HREF="::root::gdip/Structures, types and makros/dashcap.html.html">dashcap</a> ::def:: ||type-dashstyle|| ! <a HREF="::root::gdip/Structures, types and makros/dashstyle.html.html">dashstyle</a> ::def:: ||type-linejoin|| ! <a HREF="::root::gdip/Structures, types and makros/linejoin.html.html">linejoin</a> ::def:: ||type-ImageCodecInfo|| <a HREF="::root::gdip/Structures, types and makros/ImageCodecInfo.html">ImageCodecInfo</a> ::site:: gdip --- 5,32 ---- ::def:: ||type-unit|| ! <a HREF="::root::gdip/Structures, types and makros/units.html">units</a> ::def:: ||type-linecap|| ! <a HREF="::root::gdip/Structures, types and makros/linecaps.html">linecaps</a> ::def:: ||type-dashcap|| ! <a HREF="::root::gdip/Structures, types and makros/dashcaps.html">dashcaps</a> ::def:: ||type-dashstyle|| ! <a HREF="::root::gdip/Structures, types and makros/dashstyles.html">dashstyles</a> ::def:: ||type-linejoin|| ! <a HREF="::root::gdip/Structures, types and makros/linejoins.html">linejoins</a> ::def:: ||type-ImageCodecInfo|| <a HREF="::root::gdip/Structures, types and makros/ImageCodecInfo.html">ImageCodecInfo</a> + ::def:: ||type-ImageFlags|| + <a HREF="::root::gdip/Structures, types and makros/ImageFlags.html">ImageFlags</a> + + ::def:: ||type-IColorPalette|| + <a HREF="::root::gdip/Structures, types and makros/ColorPalette.html">ColorPalette</a> + C ::site:: gdip *************** *** 47,54 **** --- 53,446 ---- + + ::folder:: tructures, types and makros + + ::site:: ColorPalette + + <code class=import>defined in: wnd.gdip</code><br><br> + Structure used with palettes<br> + + <P> + <strong>Members:</strong><br> + <DL> + <DT>Flags + <DD>palette flags (currently not used) + <DT>Count + <DD>number of entries in the palete + <DT>Entries + <DD>an array of Count size length containing the ARGB color values + </DL> + <br><br> + + + + ::site:: Units + <TABLE class="table1" BORDER="1"> + <TR> + <TD>UnitWorld</TD> + <TD>World coordinate (non-physical unit)</TD> + </TR> + <TR> + <TD>UnitDisplay</TD> + <TD>Variable -- for PageTransform only</TD> + </TR> + <TR> + <TD>UnitPixel</TD> + <TD>Each unit is one device pixel.</TD> + </TR> + <TR> + <TD>UnitPoint</TD> + <TD>Each unit is a printer's point, or 1/72 inch.</TD> + </TR> + <TR> + <TD>UnitInch</TD> + <TD>Each unit is 1 inch.</TD> + </TR> + <TR> + <TD>UnitDocument</TD> + <TD>Each unit is 1/300 inch.</TD> + </TR> + <TR> + <TD>UnitMillimeter</TD> + <TD>Each unit is 1 millimeter.</TD> + </TR> + </TABLE> + + + ::site:: Linecaps + <TABLE class="table1" BORDER="1"> + <TR> + <TD>LineCapFlat</TD> + <TD></TD> + </TR> + <TR> + <TD>LineCapSquare</TD> + <TD></TD> + </TR> + <TR> + <TD>LineCapRound</TD> + <TD></TD> + </TR> + <TR> + <TD>LineCapNoAnchor </TD> + <TD>corresponds to flat cap</TD> + </TR> + <TR> + <TD>LineCapSquareAnchor </TD> + <TD>orresponds to square cap</TD> + </TR> + <TR> + <TD>LineCapRoundAnchor</TD> + <TD>corresponds to round cap</TD> + </TR> + <TR> + <TD>LineCapDiamondAnchor</TD> + <TD>corresponds to triangle cap</TD> + </TR> + <TR> + <TD>LineCapArrowAnchor</TD> + <TD>no correspondence</TD> + </TR> + <TR> + <TD>LineCapCustom</TD> + <TD>custom cap</TD> + </TR> + <TR> + <TD>LineCapAnchorMask</TD> + <TD>mask to check for anchor or not. </TD> + </TR> + </TABLE> + + + ::site:: Dashstyles + <TABLE class="table1" BORDER="1"> + <TR> + <TD>DashStyleSolid</TD> + <TD></TD> + </TR> + <TR> + <TD>DashStyleDash</TD> + <TD></TD> + </TR> + <TR> + <TD>DashStyleDashDot</TD> + <TD></TD> + </TR> + <TR> + <TD>DashStyleDashDotDot</TD> + <TD></TD> + </TR> + <TR> + <TD>DashStyleCustom</TD> + <TD></TD> + </TR> + </TABLE> + + + ::site:: Dashcaps + <TABLE class="table1" BORDER="1"> + <TR> + <TD>DashCapFlat</TD> + <TD></TD> + </TR> + <TR> + <TD>DashCapRound</TD> + <TD></TD> + </TR> + <TR> + <TD>DashCapTriangle</TD> + <TD></TD> + </TR> + </TABLE> + + + ::site:: Linejoins + <TABLE class="table1" BORDER="1"> + <TR> + <TD>LineJoinMiter</TD> + <TD></TD> + </TR> + <TR> + <TD>LineJoinBevel </TD> + <TD></TD> + </TR> + <TR> + <TD>LineJoinMiterClipped</TD> + <TD></TD> + </TR> + </TABLE> + + + ::site:: ImageFlags + <TABLE class="table1" BORDER="1"> + <TR> + <TD>ImageFlagsNone</TD> + <TD></TD> + </TR> + <TR> + <TD>ImageFlagsScalable</TD> + <TD></TD> + </TR> + <TR> + <TD>ImageFlagsHasAlpha</TD> + <TD></TD> + </TR> + <TR> + <TD>ImageFlagsHasTranslucent</TD> + <TD></TD> + </TR> + <TR> + <TD>ImageFlagsPartiallyScalable</TD> + <TD></TD> + </TR> + <TR> + <TD>ImageFlagsColorSpaceRGB</TD> + <TD></TD> + </TR> + <TR> + <TD>ImageFlagsColorSpaceCMYK</TD> + <TD></TD> + </TR> + <TR> + <TD>ImageFlagsColorSpaceGRAY</TD> + <TD></TD> + </TR> + <TR> + <TD>ImageFlagsColorSpaceYCBCR</TD> + <TD></TD> + </TR> + <TR> + <TD>ImageFlagsHasRealDPI</TD> + <TD></TD> + </TR> + <TR> + <TD>ImageFlagsHasRealPixelSize</TD> + <TD></TD> + </TR> + <TR> + <TD>ImageFlagsReadOnly</TD> + <TD></TD> + </TR> + <TR> + <TD>ImageFlagsCaching</TD> + <TD></TD> + </TR> + </TABLE> + + ::site:: Foo + <TABLE class="table1" BORDER="1"> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD>/TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + </TABLE> + + + + + ::site:: Foo + <TABLE class="table1" BORDER="1"> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD>/TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + </TABLE> + + + + + + + ::site:: Foo + <TABLE class="table1" BORDER="1"> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD>/TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + <TR> + <TD></TD> + <TD></TD> + </TR> + </TABLE> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file |
From: jürgen u. <cer...@us...> - 2005-08-14 15:56:02
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/gdip/ImageCodec In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31420/wnd_doc/doc/gdip/ImageCodec Added Files: imagecodec.dtpl Log Message: comb over --- NEW FILE: imagecodec.dtpl --- # ::defaultpage:: class ImageEncoder ::site:: class ImageDecoder <code class=import>defined in: wnd.gdip</code><br><br> <code>ImageEncoder()</code><br> <P> Initializes a class for handling image encoders <P> ::site:: class ImageEncoder <code class=import>defined in: wnd.gdip</code><br><br> <code>ImageEncoder()</code><br> <P> Initializes a class for handling image encoders The class contains the following constants to interpret the Flags member of a ||type-ImageCodecInfo|| structure: <br><br> <TABLE class="table1" BORDER="1"> <TR> <TD>SupportBitmap</TD> <TD>the codec supports bitmaps</TD> <TR> <TR> <TD>BlockingDecode</TD> <TD>indicates that the codec blocks during decoding</TD> <TR> <TR> <TD>Builtin</TD> <TD>the codec is gdi+ builtin</TD> <TR> <TR> <TD>Decoder</TD> <TD>the codec supports decoding</TD> <TR> <TR> <TD>Encoder</TD> <TD>the codec supports encoding</TD> <TR> <TR> <TD>SeekableEncode</TD> <TD>indicates that the codec requires a seekable output stream</TD> <TR> <TR> <TD>SupportVector</TD> <TD>the codec supports vector images</TD> <TR> </TABLE> <br><br> You would use this class to iterate over all image encoders currently available on the system. </P> ::folder:: ImageEncoder and ImageDecoder methods ::item:: __iter__ <code>__iter__()</code><br> <P>Iterates over all available image encoders returning the next ||type-ImageCodecInfo|| in turn, describing an image encoder. </P> ::item:: GetCodecSignature <code>GetCodecSignature(Encoder)</code><br> <P>Retrives the SigPattern and SigMask members of a ||type-ImageCodecInfo|| structure and returns them as tuple(arrayPattern, arrayMask) </P> |
From: jürgen u. <cer...@us...> - 2005-08-14 15:56:02
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/gdip/ImageDecoder In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31420/wnd_doc/doc/gdip/ImageDecoder Removed Files: .CVSIGNORE ImageDecoder.dtpl Log Message: comb over --- .CVSIGNORE DELETED --- --- ImageDecoder.dtpl DELETED --- |
From: jürgen u. <cer...@us...> - 2005-08-14 15:56:01
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/gdip/ImageEncoder In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31420/wnd_doc/doc/gdip/ImageEncoder Removed Files: ImageEncoder.dtpl Log Message: comb over --- ImageEncoder.dtpl DELETED --- |
From: jürgen u. <cer...@us...> - 2005-08-14 15:54:56
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/gdip/ImageCodec In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv31265/ImageCodec Log Message: Directory /cvsroot/wnd/wnd/wnd_doc/doc/gdip/ImageCodec added to the repository |
From: jürgen u. <cer...@us...> - 2005-07-23 22:28:47
|
Update of /cvsroot/wnd/wnd/wnd/tools/dlgeditor In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30901/wnd/tools/dlgeditor Modified Files: dlgeditor.py Log Message: test Index: dlgeditor.py =================================================================== RCS file: /cvsroot/wnd/wnd/wnd/tools/dlgeditor/dlgeditor.py,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** dlgeditor.py 23 Jul 2005 19:34:46 -0000 1.2 --- dlgeditor.py 23 Jul 2005 22:28:39 -0000 1.3 *************** *** 9,15 **** NOTES - - - Init a new DialogDlgTemplate by specifying classname (can be None), title, x, y, w, h, font and styles for the main frame. --- 9,12 ---- |
From: jürgen u. <cer...@us...> - 2005-07-23 22:10:16
|
Update of /cvsroot/wnd/wnd/wnd/controls/base In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv26713/wnd/controls/base Modified Files: control.py dialog.py methods.py window.py Log Message: bit of this and a bit of that Index: control.py =================================================================== RCS file: /cvsroot/wnd/wnd/wnd/controls/base/control.py,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** control.py 2 Jul 2005 09:53:42 -0000 1.3 --- control.py 23 Jul 2005 22:10:05 -0000 1.4 *************** *** 9,13 **** NMHDR, UINT, ! DLGCODES,) from wnd import fwtypes as fw #::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: --- 9,15 ---- NMHDR, UINT, ! DLGCODES, ! LOWORD, ! HIWORD) from wnd import fwtypes as fw #::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: *************** *** 26,30 **** self._base_debugger= None self._base_fMsgReflect= 1 ! # ...all the style parsing --- 28,33 ---- self._base_debugger= None self._base_fMsgReflect= 1 ! self._base_guid = None ! # ...all the style parsing *************** *** 94,100 **** result = self.onMESSAGE(hwnd, msg, wp, lp) if result !=None: return result ! #--------------------------------------------------- --- 97,128 ---- + result = self.onMESSAGE(hwnd, msg, wp, lp) + + # have to process here, coos default retval is 0 from childwindow handlers + if msg==fw.WND_WM_NOTIFY: + if wp== fw.WND_NM_GETGUID: + guid= self.GetGUID() + if guid: + fw.CopyData(self.Hwnd, lp, fw.WND_CD_GUID, guid, 1) + return 1 + return 0 + if result !=None: return result ! ! ! ! # copydata ------------------------------------------------------- ! ! elif msg== self.Msg.WM_COPYDATA: ! ! result = fw.HandleCopyData(hwnd, msg, wp, lp) ! if result == None: ! return 0 ! if HIWORD(result[0]): # reserved for framework, must be mislead ! return 0 ! if self.onMSG(hwnd, "copydata", wp, (result[0], result[1]))== False: ! return 0 ! return 1 #--------------------------------------------------- *************** *** 135,138 **** --- 163,172 ---- + + + + + + elif msg==self.Msg.WM_DROPFILES: pt=POINT() *************** *** 163,166 **** --- 197,207 ---- elif msg==self.Msg.WM_DESTROY: + + ID= user32.GetWindowLongA(self.Hwnd, -12) # GWL_ID + if ID: + try: + fw.ID.Recycle(ID) + except: pass + if self._base_dragAcceptFiles: shell32.DragAcceptFiles(self.Hwnd, 0) *************** *** 179,183 **** # default return self.DefWindowProc(hwnd, msg, wp, lp) ! --- 220,224 ---- # default return self.DefWindowProc(hwnd, msg, wp, lp) ! *************** *** 223,227 **** raise "invalid flag: %s" % i - self.Hwnd=hwnd self._base_style = [0, 0] # base/clientstyle --- 264,267 ---- *************** *** 233,242 **** self._base_debugger= None self._base_fMsgReflect= 1 ! ! # set the windowproc ! self._base_pWndProc= WNDPROC(self._base_WndProc) self._base_pOldWndProc = 0 ! if not 'nosubclass' in styles: # check if debugging is requested and set the windowproc dbglevel= 0 --- 273,288 ---- self._base_debugger= None self._base_fMsgReflect= 1 ! self._base_guid = None ! # set the windowproc ! self._base_pWndProc= 0 self._base_pOldWndProc = 0 ! if 'nosubclass' in styles: ! self._base_subclassable = False ! ! else: ! ## leaks for MDI childwindows if setup with 'nosubclass' ?? ! self._base_pWndProc= WNDPROC(self._base_WndProc) ! # check if debugging is requested and set the windowproc dbglevel= 0 *************** *** 245,249 **** self._base_debugger= fw.GetDebugger(dbglevel, self.Msg) - if 'subclass' in styles: self.Subclass() --- 291,294 ---- *************** *** 278,282 **** #WS_SYSMENU = 524288 #WS_POPUPWINDOW = WS_POPUP | WS_BORDER | WS_SYSMENU ! control_styles.__dict__.update(fw.wnd_window_styles.__dict__) --- 323,327 ---- #WS_SYSMENU = 524288 #WS_POPUPWINDOW = WS_POPUP | WS_BORDER | WS_SYSMENU ! control_styles.__dict__.update(fw.wnd_control_styles.__dict__) *************** *** 309,312 **** --- 354,358 ---- WM_WINDOWPOSCHANGING = 70 WM_WINDOWPOSCHANGED = 71 + WM_COPYDATA = 74 WM_NOTIFY = 78 WM_CONTEXTMENU = 123 Index: window.py =================================================================== RCS file: /cvsroot/wnd/wnd/wnd/controls/base/window.py,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** window.py 2 Jul 2005 09:53:42 -0000 1.3 --- window.py 23 Jul 2005 22:10:05 -0000 1.4 *************** *** 3,10 **** --- 3,12 ---- from wnd.wintypes import (user32, shell32, + kernel32, c_short, byref, addressof, pointer, + GetLastError, POINT, create_string_buffer, *************** *** 15,19 **** UINT, NMHDR, ! MINMAXINFO,) from wnd import fwtypes as fw --- 17,23 ---- UINT, NMHDR, ! MINMAXINFO, ! LOWORD, ! HIWORD) from wnd import fwtypes as fw *************** *** 74,77 **** --- 78,85 ---- + if fw.WND_GUIMAIN: + raise RuntimeError, "a GUI can only have one main window" + fw.WND_GUIMAIN = True + #self.Data= Data() *************** *** 82,89 **** self._base_dragAcceptFiles=False self._base_timers= [] self._base_fIsopen= False # WM_SIZE needs this, not notify the user # unless the gui is open self._base_debugger= None ! # styles iStyles = self.ParseStyles(styles) --- 90,101 ---- self._base_dragAcceptFiles=False self._base_timers= [] + self._base_hwndDlgMsg= 0 ## hwnd for wich 'IsDialogMsg' dispatches + self._base_fIsopen= False # WM_SIZE needs this, not notify the user # unless the gui is open self._base_debugger= None ! self._base_guid = None ! self._base_mutext_singleinst = None ! # styles iStyles = self.ParseStyles(styles) *************** *** 118,130 **** --- 130,152 ---- #ExitHandler._RegisterGuiExitFunc(user32.DestroyWindow, self.Hwnd) + self._base_hwndDlgMsg= self.Hwnd + + + #-------------------------------------------------------------------- def _base_WndProc(self, hwnd, msg, wp, lp): try: + #if msg==fw.WND_WM_NOTIFY: + # print 1 + # return 0 + if self._base_debugger: result= self._base_debugger.HandleMessage(hwnd, msg, wp, lp) if result: self.onMSG(hwnd, "debug", *result) + + result= fw.IsReflectMessage(hwnd, msg, wp, lp) if result != None: return result *************** *** 134,137 **** --- 156,161 ---- + + #------------------------------------------------------------------- if msg==43: # WM_DRAWITEM *************** *** 160,163 **** --- 184,189 ---- if self._base_dragAcceptFiles: shell32.DragAcceptFiles(self.Hwnd, 0) + if self._base_mutext_singleinst: + kernel32.CloseHandle(self._base_mutext_singleinst) return 0 *************** *** 314,320 **** ! #-------------------------------------------------------- ! # framework messages elif msg==fw.WND_WM_NOTIFY: if wp==fw.WND_NM_MENU: mnu= fw.WND_MENU.from_address(lp) --- 340,361 ---- ! # copydata ------------------------------------------------------- ! ! elif msg== self.Msg.WM_COPYDATA: ! ! result = fw.HandleCopyData(hwnd, msg, wp, lp) ! if result == None: ! return 0 ! if HIWORD(result[0]): # reserved for framework, must be mislead ! return 0 ! if self.onMSG(hwnd, "copydata", wp, (result[0], result[1]))== False: ! return 0 ! return 1 ! ! ! # framework messages ------------------------------------------------------- ! elif msg==fw.WND_WM_NOTIFY: + if wp==fw.WND_NM_MENU: mnu= fw.WND_MENU.from_address(lp) *************** *** 336,339 **** --- 377,400 ---- return 0 + elif wp== fw.WND_NM_DLGDISPATCH: + if lp: self._base_hwndDlgMsg = lp + else: self._base_hwndDlgMsg = self.Hwnd + + elif wp== fw.WND_NM_GETGUID: + guid= self.GetGUID() + if guid: + fw.CopyData(self.Hwnd, lp, fw.WND_CD_GUID, guid, 1) + return 1 + return 0 + + + elif wp== fw.WND_NM_ISMAINWINDOW: + return fw.WND_MSGRESULT_TRUE + + elif wp== fw.WND_NM_ISFWWINDOW: + return fw.WND_MSGRESULT_TRUE + + + elif wp==fw.WND_NM_EXCEPTION: nexc= fw.WND_EXCEPTION.from_address(lp) *************** *** 422,425 **** --- 483,487 ---- user32.TranslateAcceleratorA) msg = MSG() + pMsg = pointer(msg) if self.GetStyleL('basestyle') & self.Style.WS_BASE_DIALOGLIKE: *************** *** 435,439 **** _exit.Unregister(self.Hwnd) while GM( pMsg, 0, 0, 0) > 0: ! if not IsDialogMessage(self.Hwnd, pMsg): if self._base_hAccelerator: if not TACC(self.Hwnd, self._base_hAccelerator, pMsg): --- 497,501 ---- _exit.Unregister(self.Hwnd) while GM( pMsg, 0, 0, 0) > 0: ! if not IsDialogMessage(self._base_hwndDlgMsg, pMsg): if self._base_hAccelerator: if not TACC(self.Hwnd, self._base_hAccelerator, pMsg): *************** *** 442,445 **** --- 504,509 ---- TM(pMsg) DM(pMsg) + + else: self.onMSG(self.Hwnd, "open", 0, 0) Index: methods.py =================================================================== RCS file: /cvsroot/wnd/wnd/wnd/controls/base/methods.py,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** methods.py 2 Jul 2005 09:53:42 -0000 1.3 --- methods.py 23 Jul 2005 22:10:05 -0000 1.4 *************** *** 1,4 **** - import gc from wnd import fwtypes as fw --- 1,3 ---- *************** *** 6,9 **** --- 5,9 ---- gdi32, shell32, + kernel32, addressof, byref, *************** *** 17,20 **** --- 17,21 ---- INT, c_long, + c_ulong, c_ushort, HANDLE, *************** *** 39,42 **** --- 40,97 ---- + """***************************************************************************** + Creates a name postfixed with either the curent desktop name + the current sesion id or the current user domain + + This applies to NT systems only. For win9x systems the name is returned + unchanged. If something goes wrong the name is returnd unchanged. + + flag can be: 'desktop', 'session' or 'trustee' + + + code is adopted from: + http://www.flounder.com/nomultiples.htm + + *****************************************************************************""" + def CreateExclusionName(name, flag): + from wnd.api import winos + if winos.IsNT(): + + if flag=='desktop': + ## create a name exclusive to the current desktop + #UOI_NAME = 2 + hDesk= user32.GetThreadDesktop(kernel32.GetCurrentThreadId()) + + dwLen= c_ulong() + user32.GetUserObjectInformationA(hDesk, 2, None, 0, byref(dwLen)) + p = create_string_buffer('', size=dwLen.value) + if user32.GetUserObjectInformationA(hDesk, 2, p, dwLen.value, byref(dwLen)): + name = '%s-%s' % (name, p.value) + user32.CloseDesktop(hDesk) + return name + + elif flag== 'session': + ## create a name exclusive to the current session + from wnd.api import privleges + try: + st= privleges.GetTokenStats(None) + name = '%s-%s' % (name, st.AuthenticationId) + except: pass + return name + + elif flag == 'trustee': + ## create a name exclusive to the current, well trustee that is. + import os + domain= os.getenv('USERDOMAIN') + if domain: + return '%s-%s' % (name, domain) + + # default + return name + + + #*********************************************************************************** + #*********************************************************************************** + ENUMWINDOWSPROC = WINFUNCTYPE(INT, HANDLE, LPARAM) *************** *** 104,110 **** # #******************************************************************* ! def ChildWindows(self, flag=None): ! return _EnumWindows.ChildWindows(self.Hwnd) def WalkGui(self, hwnd=None, topdown=True): --- 159,175 ---- # #******************************************************************* ! ! ! def GetGUID(self): ! return self._base_guid ! ! def SetGUID(self, guid): ! self._base_guid= guid ! ! def ThreadWindows(self, flag=None): ! return _EnumWindows.ThreadWindows(self.Hwnd, flag) ! def ChildWindows(self, flag=None): ! return _EnumWindows.ChildWindows(self.Hwnd) def WalkGui(self, hwnd=None, topdown=True): *************** *** 615,618 **** --- 680,684 ---- def Subclass(self): + if not self._base_pWndProc: raise RuntimeError, "can not subclass control" if self._base_pOldWndProc: raise RuntimeError, "control is alreaddy subclassed" if not self._base_subclassable: raise RuntimeError, "custom classes should not be subclassed" *************** *** 624,627 **** --- 690,694 ---- if self.IsSubclassed(): user32.SetWindowLongA(self.Hwnd, -4, self._base_pOldWndProc) + user32.DestroyWindow(self.Hwnd) self.__delattr__('Hwnd') *************** *** 636,639 **** --- 703,750 ---- class WindowMethods(_CommonMethods): + def ForceSingleInstance(self, Bool, restore=True, flag=None): + + if Bool: + if self.GetGUID(): + ERROR_ACCESS_DENIED = 5 + ERROR_ALREADY_EXISTS = 183 + + fRunning= False + if self._base_mutext_singleinst: + fRunning= True + else: + if flag: + if flag in ('desktop', 'session', 'trustee'): + self._base_mutext_singleinst= kernel32.CreateMutexA(None, 0, CreateExclusionName(self._base_guid, flag)) + else: raise ValueError, "invalid flag: %s" % flag + else: + self._base_mutext_singleinst= kernel32.CreateMutexA(None, 0, self._base_guid) + if GetLastError() in (ERROR_ALREADY_EXISTS, ERROR_ACCESS_DENIED): + kernel32.CloseHandle(self._base_mutext_singleinst) + self._base_mutext_singleinst= None + fRunning= True + + if fRunning: + if restore: + ## take advantage of copydata FindGUID method here + from wnd.api import copydata + cd= copydata.CopyData() + hwnd= cd.FindGUID(self.Hwnd, self.GetGUID()) + + if hwnd: + user32.SetForegroundWindow(hwnd) + if user32.IsIconic(hwnd): + user32.ShowWindow(hwnd, 9) # SW_RESTORE + + self.Close() + raise RuntimeError, "single instance enforced" + else: + raise RuntimeError, "GUID is required" + else: + if self._base_mutext_singleinst: + kernel32.CloseHandle(self._base_mutext_singleinst) + self._base_mutext_singleinst= None + + def SetBkColor(self, Brush): oldbrush = user32.SetClassLongA(self.Hwnd, -10, Brush.handle) # GCL_HBRBACKGROUND *************** *** 757,763 **** ! ! ! def Close(self): user32.DestroyWindow(self.Hwnd) --- 868,875 ---- ! def Close(self): ! if self.Hwnd: ! user32.DestroyWindow(self.Hwnd) ! self.hwnd= 0 Index: dialog.py =================================================================== RCS file: /cvsroot/wnd/wnd/wnd/controls/base/dialog.py,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** dialog.py 29 Apr 2005 15:23:33 -0000 1.1.1.1 --- dialog.py 23 Jul 2005 22:10:05 -0000 1.2 *************** *** 1,3 **** --- 1,12 ---- + """ + TODO + - disallow multiple creation of the same dialog + propsheets bypass the Run method-- how to stop them ?? + + - 'dialoglike' keyboard handling for standalone dialogs (modeless) + have to run a dispatch loop for this + + """ from wnd.wintypes import (user32, *************** *** 9,13 **** NMHDR, WORD, - UINT, POINT, byref, --- 18,21 ---- *************** *** 18,22 **** --- 26,35 ---- #::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: + PSM_QUERYSIBLINGS = 1024 + 108 # WM_USER # propertysheets + + #******************************************************************************** + #******************************************************************************** + class BaseDialog(object): *************** *** 25,28 **** --- 38,43 ---- def __init__(self, title, x, y, w, h, *styles): + + self.Hwnd= 0 self.Msg = dialog_msgs self.Style = dialog_styles *************** *** 31,38 **** self._base_registeredMessages = [] self._base_dragAcceptFiles=False ! self._base_dialogMode=None self._base_timers= [] self._base_debugger= None ! # styles iStyles = self.ParseStyles(styles) --- 46,57 ---- self._base_registeredMessages = [] self._base_dragAcceptFiles=False ! self._base_dialogMode='modeless' ## in respect to property sheets ! ## ! self._base_timers= [] self._base_debugger= None ! self._base_guid = None ! ! # styles iStyles = self.ParseStyles(styles) *************** *** 56,87 **** self._base_dlgTemplate = buffer((WORD * len(p))(*p))[:] #--------------------------------------------------------------------- # for uniformity reasons def DefWindowProc(self, Hwnd, msg, wp, lp): ! return self.DefDlgProc def _base_WndProc(self, hwnd, msg, wp, lp): try: ! if self._base_debugger: result= self._base_debugger.HandleMessage(hwnd, msg, wp, lp) if result: self.onMSG(hwnd, "debug", *result) ! result= fw.IsDialogReflectMessage(hwnd, msg, wp, lp) ! if result != None: return result ! result=self.onMESSAGE(hwnd, msg, wp, lp) if result != None: return result - if msg == self.Msg.WM_INITDIALOG: - self.Hwnd = hwnd - self.onINITDIALOG(hwnd, msg, wp, lp) - return 0 # ?? #--------------------------------------------------------------------------- elif msg==self.Msg.WM_SYSCOLORCHANGE: ## forward to all child windows --- 75,154 ---- self._base_dlgTemplate = buffer((WORD * len(p))(*p))[:] + + + + #--------------------------------------------------------------------- # for uniformity reasons def DefWindowProc(self, Hwnd, msg, wp, lp): ! return self.DefDlgProc(Hwnd, msg, wp, lp) def _base_WndProc(self, hwnd, msg, wp, lp): + try: ! if self._base_debugger: result= self._base_debugger.HandleMessage(hwnd, msg, wp, lp) if result: self.onMSG(hwnd, "debug", *result) ! result= fw.IsDialogReflectMessage(hwnd, msg, wp, lp, self._base_dialogMode) ! if result != None: return result ! ! ! if msg == self.Msg.WM_INITDIALOG: ! self.Hwnd= hwnd ! result= self.onINITDIALOG(hwnd, msg, wp, lp) ! if result != None: return result ! return 0 ! result=self.onMESSAGE(hwnd, msg, wp, lp) if result != None: return result + #--------------------------------------------------------------------------- + elif msg==self.Msg.WM_ACTIVATE: + #WA_INACTIVE = 0 + #WA_ACTIVE = 1 + #WA_CLICKACTIVE = 2 + + if self.GetStyleL('basestyle') & self.Style.WS_BASE_DIALOGLIKE: + ## tell the mainwindow to dispatch/clear IsDialogMessage + + hwndMain= self.GetMainWindow() + if hwndMain: + if LOWORD(wp) & 3: # activated + + self.SendMessage(hwndMain, fw.WND_WM_NOTIFY, fw.WND_NM_DLGDISPATCH, self.Hwnd) + else: + self.SendMessage(hwndMain, fw.WND_WM_NOTIFY, fw.WND_NM_DLGDISPATCH, 0) # clear + + + + # copydata ------------------------------------------------------- + + elif msg== self.Msg.WM_COPYDATA: + result = fw.HandleCopyData(hwnd, msg, wp, lp) + if result == None: + return 0 + if HIWORD(result[0]): # reserved for framework, must be mislead + return 0 + if self.onMSG(hwnd, "copydata", wp, (result[0], result[1]))== False: + return 0 + return 1 + + + + ## property sheets + elif msg==PSM_QUERYSIBLINGS: + result= self.onMSG(hwnd, "prop_querysiblings", wp, lp) + if result: return result + return 0 + + elif msg==self.Msg.WM_SYSCOLORCHANGE: ## forward to all child windows *************** *** 103,109 **** elif msg==self.Msg.WM_COMMAND: - ## filter out default IDS for 'modal' dialog boxes if self._base_dialogMode=='modal': ! # we can not set ID of the def button to IDOK # so we have to explicitely test for it --- 170,175 ---- elif msg==self.Msg.WM_COMMAND: if self._base_dialogMode=='modal': ! ## filter out default IDS for 'modal' dialog boxes # we can not set ID of the def button to IDOK # so we have to explicitely test for it *************** *** 124,134 **** else: self.Close() return 0 ! else: ! if HIWORD(wp): # accelerator message ! self.onMSG(hwnd, "menu choice", user32.GetMenu(self.Hwnd), (LOWORD(wp), True)) ! else: # menu message self.onMSG(hwnd, "menu choice", user32.GetMenu(self.Hwnd), (LOWORD(wp), False)) ! elif msg==fw.WND_WM_TRAY: --- 190,205 ---- else: self.Close() return 0 + + #if lp: + # WM_COMMAND from non framework controls or controls wich + # have disabled the message reflect flag, so let them splip ! if not lp: ! code= HIWORD(wp) ! if code==0: # menu message self.onMSG(hwnd, "menu choice", user32.GetMenu(self.Hwnd), (LOWORD(wp), False)) ! elif code==1: # accelerator message ! self.onMSG(hwnd, "menu choice", user32.GetMenu(self.Hwnd), (LOWORD(wp), True)) ! elif msg==fw.WND_WM_TRAY: *************** *** 190,194 **** # drag window by its client area --------------------------------------------------- ! ## does not work for dialogs ## #elif msg==132: # WM_NCHITTEST --- 261,265 ---- # drag window by its client area --------------------------------------------------- ! ## does not work for dialogs ?? ## #elif msg==132: # WM_NCHITTEST *************** *** 211,216 **** if self._base_dragAcceptFiles: shell32.DragAcceptFiles(self.Hwnd, 0) self.onMSG(hwnd, "destroy", 0, 0) ! self.__delattr__('Hwnd') --- 282,290 ---- if self._base_dragAcceptFiles: shell32.DragAcceptFiles(self.Hwnd, 0) + self._base_dragAcceptFiles=False + + self.Hwnd= 0 self.onMSG(hwnd, "destroy", 0, 0) ! *************** *** 229,232 **** --- 303,307 ---- raise RuntimeError, "could not redraw menu bar" return 1 + elif nmu.type==fw.MNUT_ACCEL: # remove accelerator table *************** *** 235,238 **** --- 310,320 ---- return 1 return 0 + + elif wp== fw.WND_NM_GETGUID: + guid= self.GetGUID() + if guid: + fw.CopyData(self.Hwnd, lp, fw.WND_CD_GUID, guid, 1) + return 1 + return 0 elif wp==fw.WND_NM_EXCEPTION: *************** *** 291,301 **** elif self._base_dialogMode=='modeless': user32.DestroyWindow(self.Hwnd) ! #self.__delattr__('Hwnd') def RunModal(self, parent=None, lp=0): ! if hasattr(self, 'Hwnd'): raise RuntimeError("Dialog allreaddy running") if not parent: parent= 0 else: parent= parent.Hwnd self._base_dialogMode = 'modal' result = user32.DialogBoxIndirectParamA( --- 373,384 ---- elif self._base_dialogMode=='modeless': user32.DestroyWindow(self.Hwnd) ! def RunModal(self, parent=None, lp=0): ! if self.Hwnd: raise RuntimeError("Dialog allreaddy running") if not parent: parent= 0 else: parent= parent.Hwnd + self._base_dialogMode = 'modal' result = user32.DialogBoxIndirectParamA( *************** *** 306,310 **** def RunModeless(self, parent=None, lp=0): ! if hasattr(self, 'Hwnd'): raise RuntimeError("Dialog allreaddy running") if not parent: parent= 0 --- 389,393 ---- def RunModeless(self, parent=None, lp=0): ! if self.Hwnd: raise RuntimeError("Dialog allreaddy running") if not parent: parent= 0 *************** *** 314,320 **** 0, self._base_dlgTemplate, parent, self._base_pWndProc , lp) ! ## when to collect here ?? ! gc.collect() ! def onINITDIALOG(self, hwnd, msg, wp, lp): --- 397,402 ---- 0, self._base_dlgTemplate, parent, self._base_pWndProc , lp) ! ! def onINITDIALOG(self, hwnd, msg, wp, lp): *************** *** 329,332 **** --- 411,415 ---- """User handler. Overwrite in derrived classes""" pass + def onMSG(self, hwnd, msg, wp, lp): """User handler. Overwrite in derrived classes""" *************** *** 334,337 **** --- 417,434 ---- + def GetTemplate(self): + return self._base_dlgTemplate + + def GetDlgProc(self): + return self._base_pWndProc + + def GetMainWindow(self): + hwndMain= None + for i in self.ThreadWindows(): + result= self.SendMessage(i, fw.WND_WM_NOTIFY, fw.WND_NM_ISMAINWINDOW, 0) + if result == fw.WND_MSGRESULT_TRUE: + hwndMain= i + break + return hwndMain #*********************************************************************** *************** *** 340,343 **** --- 437,442 ---- class BaseDialogFromTemplate(BaseDialog): def __init__(self, template, *styles): + + self.Msg = dialog_msgs self.Style = dialog_styles *************** *** 348,353 **** self._base_debugger= None self._base_dialogMode=None ! self._base_style = [0, 0] # base/clientstyle ! valid_flags=('debug', 'debugall') for i in styles: --- 447,453 ---- self._base_debugger= None self._base_dialogMode=None ! self._base_style = [0, 0] # base/clientstyle ! self._base_guid = None ! valid_flags=('debug', 'debugall') for i in styles: *************** *** 365,369 **** self._base_pOldWndProc = 0 ! #************************************************************************ # base class for common-dialogs --- 465,469 ---- self._base_pOldWndProc = 0 ! #************************************************************************ # base class for common-dialogs *************** *** 387,398 **** self.Hwnd = 0 self._base_registeredMessages = [] self._base_dragAcceptFiles=False self._base_timers= [] # styles self._base_dialogMode=mode self._base_style = [0, 0] # base/clientstyle ! # check if debugging is requested and set the windowproc dbglevel= 0 --- 487,504 ---- self.Hwnd = 0 + self._base_registeredMessages = [] self._base_dragAcceptFiles=False self._base_timers= [] + self._base_guid = None # styles self._base_dialogMode=mode self._base_style = [0, 0] # base/clientstyle ! ## enables keyboard handling for 'modeless' common dialogs ! if self._base_dialogMode== 'modeless': ! self._base_style[0] |= self.Style.WS_BASE_DIALOGLIKE ! ! # check if debugging is requested and set the windowproc dbglevel= 0 *************** *** 404,409 **** ! def GetDlgProc(self): ! return self._base_pWndProc def Close(self): --- 510,516 ---- ! def GetTemplate(self): ! return None ! def Close(self): |
From: jürgen u. <cer...@us...> - 2005-07-23 22:10:15
|
Update of /cvsroot/wnd/wnd/wnd/api/shell In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv26713/wnd/api/shell Removed Files: browseforfolder.py Log Message: bit of this and a bit of that --- browseforfolder.py DELETED --- |
From: jürgen u. <cer...@us...> - 2005-07-23 22:10:15
|
Update of /cvsroot/wnd/wnd/wnd In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv26713/wnd Modified Files: fwtypes.py Log Message: bit of this and a bit of that Index: fwtypes.py =================================================================== RCS file: /cvsroot/wnd/wnd/wnd/fwtypes.py,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** fwtypes.py 23 Jul 2005 19:10:17 -0000 1.4 --- fwtypes.py 23 Jul 2005 22:10:06 -0000 1.5 *************** *** 507,511 **** return None - """***************************************************************************************** Copy Data handlers --- 507,510 ---- *************** *** 554,558 **** return (cd.dwData, ''.join(data[len(SZ_GUID_COPYDATA):])) - --- 553,556 ---- |
From: jürgen u. <cer...@us...> - 2005-07-23 22:10:14
|
Update of /cvsroot/wnd/wnd/wnd/controls/listview In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv26713/wnd/controls/listview Modified Files: messagehandler.py Log Message: bit of this and a bit of that Index: messagehandler.py =================================================================== RCS file: /cvsroot/wnd/wnd/wnd/controls/listview/messagehandler.py,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** messagehandler.py 2 Jul 2005 09:54:34 -0000 1.3 --- messagehandler.py 23 Jul 2005 22:10:06 -0000 1.4 *************** *** 14,18 **** msgr.fReturn= self._base_fMsgReflect - if msgr.msg==self.Msg.WM_NOTIFY: # custom draw --- 14,17 ---- *************** *** 110,115 **** elif msg==self.Msg.WM_DESTROY: self.onMSG(hwnd, "destroy", 0, 0) ! return 0 ! elif msg==self.Msg.WM_STYLECHANGING: # set LVS_SHAREIMAGELISTS as unchangable style --- 109,113 ---- elif msg==self.Msg.WM_DESTROY: self.onMSG(hwnd, "destroy", 0, 0) ! elif msg==self.Msg.WM_STYLECHANGING: # set LVS_SHAREIMAGELISTS as unchangable style |
From: jürgen u. <cer...@us...> - 2005-07-23 20:15:05
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/tools/dlgeditor/dlgtemplate In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv8025 Modified Files: dlgtemplate.dtpl Log Message: bit of this and a bit of that Index: dlgtemplate.dtpl =================================================================== RCS file: /cvsroot/wnd/wnd/wnd_doc/doc/tools/dlgeditor/dlgtemplate/dlgtemplate.dtpl,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** dlgtemplate.dtpl 29 Apr 2005 15:15:22 -0000 1.1.1.1 --- dlgtemplate.dtpl 23 Jul 2005 20:14:57 -0000 1.2 *************** *** 4,10 **** <code class=import>defined in: wnd.tools.dlgeditor.dlgtemplate</code><br><br> <code>DlgTemplate()</code><br> ! Bare bones dialog editor to create Dialog templates you can save to file ! or whatever. ! <br><br> --- 4,10 ---- <code class=import>defined in: wnd.tools.dlgeditor.dlgtemplate</code><br><br> <code>DlgTemplate()</code><br> ! Still bare bones dialog template based on DLGTEMPLATEEX and ! DLGITEMTEMPLATEEX structures. ! <br><br> *************** *** 52,55 **** --- 52,56 ---- + ::folder:: DlgTemplate methods *************** *** 72,76 **** <DD>size and position of the main form <DT>font ! <DD>a four-tuple(face-name, size, weight (0-1000), italic (1 or 0)) </DL> --- 73,77 ---- <DD>size and position of the main form <DT>font ! <DD>a four-tuple(face-name, size, weight (0-1000), italic (1 or 0)) or None </DL> *************** *** 109,112 **** --- 110,115 ---- You can pass the hwnd of the parent window and an lParam to the dialogbox if you like. + <br>Return value<br> + the hwnd of the dialogbox or None if something goes wrong </P> |
From: jürgen u. <cer...@us...> - 2005-07-23 20:13:46
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/tools/dlgeditor/dlgeditor In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7727 Modified Files: dlgeditor.dtpl Log Message: bit of this and a bit of that Index: dlgeditor.dtpl =================================================================== RCS file: /cvsroot/wnd/wnd/wnd_doc/doc/tools/dlgeditor/dlgeditor/dlgeditor.dtpl,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** dlgeditor.dtpl 29 Apr 2005 15:15:20 -0000 1.1.1.1 --- dlgeditor.dtpl 23 Jul 2005 20:13:37 -0000 1.2 *************** *** 6,12 **** <code class=import>defined in: wnd.tools.dlgeditor.dlgeditor</code><br><br> <code>DlgEditor()</code><br> ! Still bare bones dialog editor to create Dialog templates you can save to file or whatever. The styles for the controls are pased here as strings like with any other control in the framework. --- 6,19 ---- <code class=import>defined in: wnd.tools.dlgeditor.dlgeditor</code><br><br> <code>DlgEditor()</code><br> ! Still bare bones dialog editor based on DLGTEMPLATEEX and ! DLGITEMTEMPLATEEX structures. ! <br> ! To create Dialog templates you can save to file or whatever. The styles for the controls are pased here as strings like with any other control in the framework. + <br><br> + DlgEditor instances support the following methods: + <br> + <a HREF="DlgEditor methods.html">DlgEditor methods</a> *************** *** 53,62 **** - ::folder:: DlgEditor methods ::item:: BeginTemplate ! <codeBeginTemplate(classname, ID, title, x, y, w, h, *styles)</code><br> <P>Starts a new template beginning with the main form. <br><br> --- 60,68 ---- ::folder:: DlgEditor methods ::item:: BeginTemplate ! <code>BeginTemplate(classname, ID, title, x, y, w, h, font, *styles)</code><br> <P>Starts a new template beginning with the main form. <br><br> *************** *** 70,74 **** <DD>size and position of the main form <DT>font ! <DD>a four-tuple(face-name, size, weight (0-1000), italic (1 or 0)) <DT>styles <DD>the styles of the mainform. --- 76,80 ---- <DD>size and position of the main form <DT>font ! <DD>a four-tuple(face-name, size, weight (0-1000), italic (1 or 0)) or None <DT>styles <DD>the styles of the mainform. *************** *** 114,117 **** --- 120,125 ---- You can pass the hwnd of the parent window and an lParam to the dialogbox if you like. + <br>Return value<br> + the hwnd of the dialogbox or None if something goes wrong </P> *************** *** 153,154 **** --- 161,164 ---- </P> + + |
From: jürgen u. <cer...@us...> - 2005-07-23 20:13:10
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/tools In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7578 Modified Files: tools.dtpl Log Message: bit of this and a bit of that Index: tools.dtpl =================================================================== RCS file: /cvsroot/wnd/wnd/wnd_doc/doc/tools/tools.dtpl,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** tools.dtpl 29 Apr 2005 15:15:10 -0000 1.1.1.1 --- tools.dtpl 23 Jul 2005 20:12:55 -0000 1.2 *************** *** 3,5 **** ::site:: tools ! Doc here \ No newline at end of file --- 3,20 ---- ::site:: tools ! Doc here ! ! ! ::folder:: tools functions ! ! ::item:: ClipGUID ! <code>ClipGUID</code><br> ! <P>Creates a new globaly unique id and sets it to the clipboard ready to be pasted into code. ! <br><br> ! The GUID created is guaranteed to be unique round about throughout ! the solar system. This can be for example helpfull to identify a GUI ! with only a very minimal chance that anyone else has setup a GUI using ! the same id, except someone has the strange habit of cluttering ! his code with manually setting up ugly identifiers looking like this: '{CB366581-F867-11D9-B552-00112FF53A26}' ! </P> ! |
From: jürgen u. <cer...@us...> - 2005-07-23 20:12:23
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/gdi/font In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7415 Modified Files: font.dtpl Log Message: bit of this and a bit of that Index: font.dtpl =================================================================== RCS file: /cvsroot/wnd/wnd/wnd_doc/doc/gdi/font/font.dtpl,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** font.dtpl 29 Apr 2005 15:16:39 -0000 1.1.1.1 --- font.dtpl 23 Jul 2005 20:12:14 -0000 1.2 *************** *** 370,374 **** ::item:: TextOutEx ! <code>TextOutEx(dc, text, x, y, rect=None, spacing=None, *flags)</code><br> <P> Draws a string to the dc. --- 370,374 ---- ::item:: TextOutEx ! <code>TextOutEx(dc, text, x, y, *flags, **kwargs)</code><br> <P> Draws a string to the dc. *************** *** 389,407 **** <br><br> - <DT>Rect - <DD>an optional ||type-RECT|| to use for clipping or opaquing. - If 'opaque' flag is specified the rectangle is filled with the current background - color of the dc. - <br><br> - <DT>spacing - <DD>an optional a list or tuple with the intercharacter spacing (in pixels) - for each char in the string. - <br> - string='footext'<br> - spacing=(10, 20, 30,40,50,60)<br> - >> f.o..o...t....e.....x......t<br> - Spacing counts from the left edge of the char. - <br><br> - <DT>flags <DD>one of the following flags: --- 389,392 ---- *************** *** 427,430 **** --- 412,439 ---- </TR> </TABLE> + + + </DL> + <br><br> + The following keyword arguments are recognized: + + <DL> + <DT>rect + <DD>an optional ||type-RECT|| to use for clipping or opaquing. + If 'opaque' flag is specified the rectangle is filled with the current background + color of the dc. + <br><br> + <DT>spacing + <DD>an optional a list or tuple with the intercharacter spacing (in pixels) + for each char in the string. + <br> + string='footext'<br> + spacing=(10, 20, 30,40,50,60)<br> + >> f.o..o...t....e.....x......t<br> + Spacing counts from the left edge of the char. + <br><br> + + </DL> + </P> |
From: jürgen u. <cer...@us...> - 2005-07-23 20:11:57
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/gdi/bitmap In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7267 Modified Files: bitmap.dtpl Log Message: bit of this and a bit of that Index: bitmap.dtpl =================================================================== RCS file: /cvsroot/wnd/wnd/wnd_doc/doc/gdi/bitmap/bitmap.dtpl,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** bitmap.dtpl 29 Apr 2005 15:16:50 -0000 1.1.1.1 --- bitmap.dtpl 23 Jul 2005 20:11:45 -0000 1.2 *************** *** 49,53 **** --- 49,73 ---- </P> + ::site:: class BitmapFromBytes + <code class=import>defined in: wnd.gdi</code><br><br> + <code>BitmapFromBytes(w, h, colorplanes, bits, bytes)</code><br> + <P> + Creates abitmap on the fly. + <DL> + <DT>w + <DD>the width of the bitmap + <DT>h + <DD>the height of the bitmap + <DT>colorplanes + <DD>number of colorplanes used + <DT>bits + <DD>the bit depth of the bitmap + <DT>bytes + <DD>a ctypes array of bytes containing the bitmap bytes + </DL> + + + </P> ::site:: class SystemBitmap |
From: jürgen u. <cer...@us...> - 2005-07-23 20:11:27
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/controls/window classes/window In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7110 Modified Files: window.dtpl Log Message: bit of this and a bit of that Index: window.dtpl =================================================================== RCS file: /cvsroot/wnd/wnd/wnd_doc/doc/controls/window classes/window/window.dtpl,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** window.dtpl 2 Jul 2005 09:49:12 -0000 1.2 --- window.dtpl 23 Jul 2005 20:11:01 -0000 1.3 *************** *** 712,715 **** --- 712,756 ---- </P> + ::item:: ForceSingleInstance + <code>ForceSingleInstance(Bool, restore=True, flag=None)</code><br> + <P>Disallows the creation of multiple instances of a GUI. + <br><br> + <DL> + <DT>Bool + <DD>if True, the creation of multiple instances is disallowed, otherwise it is + allowed (default for all GUIs created). + <br><br> + + <DT>restore + <DD>if True the main instance is restored and activated when the user + attempts to create a second instance + <br><br> + + <DT>flag + <DD>either 'desktop', 'session' or 'trustee' or None. See notes on NT systems + <br><br> + </DL> + + + <br><br> + If the user attempts to create a second instance of a GUI and singleinstance + is enforced, any subsequently created GUI is taken down in an error. + <br><br> + To make this method work a GUI has to be assigned a GUID to identify + it throughot the system. Use the <b>SetGUID</b> (no link yet) + method to do so + + <br><br> + <b>NT systems</b><br> + When enforcing a single instance for NT systems you can set the flag either to + <b>'desktop'</b> to allow only one instance per desktop, to <b>'session'</b> to + allowonly one instance per session or to <b>'trustee'</b> to allow only one + instance per trustee. If the system is not a NT system the flag is ignored and + has no effect. + + + </P> + + # ::item:: # <code></code><br> |
From: jürgen u. <cer...@us...> - 2005-07-23 20:10:39
|
Update of /cvsroot/wnd/wnd/wnd_doc/doc/controls/window classes/mdiframe In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7002 Added Files: .CVSIGNORE mdiframe.dtpl Log Message: bit of this and a bit of that --- NEW FILE: .CVSIGNORE --- *.html *.gif --- NEW FILE: mdiframe.dtpl --- ::defaultpage:: mdiframe ::site:: MDIFrame <IMG SRC="mdiframe.gif"></IMG> <br><br> Not a beauty, but you get the idea <br><br> <a HREF="contents.html">MDIFrame contents</a> <br><br> ::site:: class MDIFrame <code class=import>defined in: wnd.controls.combobox</code><br><br> <code>MDIFrame()</code><br> <P> This is the base class for MDI windows. MDIFrames support the same messages and styles like any othe r main window. <br><br> Some step through sample of how to create a MDI window: <pre> from wnd.controls.mdiframe import MDIFrame from wnd.controls.button import Button class MyMDIFrame(MDIFrame): def __init__(self): \## init the mainframe MDIFrame.__init__(self, 'MDI test', 0, 0, 300, 300, 'sysmenu', 'sizebox') self.controls= {} ## used to keep references to the controls assigned \## to the MDI childwindows self.mdi= self.MDIClient(0, 0, w, h, popMdi.handle) self.mdi.onMSG= self.on_mdi mdi= self.mdi.NewChild('mdi child 1' % self.n, 0, 0, w, h) mdi2= self.mdi.NewChild('mdi child 2' % self.n, 0, 0, w, h) bt= Button(mdi, 'test', 0, 0, 50, 50) self.controls[mdi.Hwnd]= bt def on_mdi(self, msg, wp, lp): pass def onMSG(self, msg, wp, lp): pass w= MyMDIFrame() w.Run() </pre> <br><br> <pre> class MyMDIFrame(MDIFrame): def __init__(self): \## init the mainframe MDIFrame.__init__(self, 'MDI test', 0, 0, 300, 300, 'sysmenu', 'sizebox') self.controls= {} </pre> Nothing spectacular here. Use the MDIFrame class as base class for the window, thats it. The diect 'controls' is used later to keep references to the controls assigned to the MDI childwindows. <br><br> <pre> self.mdi= self.MDIClient(0, 0, w, h) self.mdi.onMSG= self.on_mdi </pre> This will create the MDI client window and overwrite the message handler. <br><br> <pre> mdi= self.mdi.NewChild('mdi child 1' % self.n, 0, 0, w, h) mdi2= self.mdi.NewChild('mdi child 2' % self.n, 0, 0, w, h) </pre> Now create a MDI childwindow, to be placed inside the MDI client window. Mostly the MDI childwindows are intended created and destroyed dynamically at runtime. The MDIClient comes equipped to handle this, and its not necessary to keep references to the MDI childwindows <br><br> <pre> bt= Button(mdi, 'test', 0, 0, 50, 50) self.controls[mdi.Hwnd]= bt </pre> Now assign a control to the MDI childwindow using the mdi child as parent window and keep track of the control. This has the side effect to remind the scriptor to always keep references to any control created, throughout its lifetime (the controls not the scriptors lifetime, that is). Removing a control lateron from the dict will leave quite some garbage behind. Its one of the trickiest things in ctypes to avaoid garbage completely. Here it does not work at all. So some forced garbage collection might help dealing with it. <br><br> For more detailed sample code see 'gui_mdiframe.py' in the sample-guis folder. </P> ::site:: MDIFrame keyboard accelerators The win32 api defines the following keyboard accelerators for MDI childwindows: <br><br> <TABLE class="table1" BORDER="1"> <TR> <TD>alt -</TD> <TD>opens the sytem menu</TD> </TR> <TR> <TD>ctrl F4</TD> <TD>closes the sctive MDI childwindow</TD> </TR> <TR> <TD>ctrl F6</TD> <TD>activates the nextMDI childwindow</TD> </TR> </TABLE> ::folder:: MDIFrame methods MDIFram windows support the following methods: <a HREF="||method-ctrl||">Common methods</a> + all methods supported by main windows ::item:: HasClient <code>HasClient()</code><br> <P>Returns True if the MDIFrame has a MDIClient window, False otherwise </P> ::item:: MDIClient <code>MDIClient(x, y, w, h, *styles, **kwargs)</code><br> <P> Creates the client window to host the MDI child windows <br><br> <DL> <DT>x, y, w, h <DD>the desired size and position of the MDI client window <DT>*styles <DD>any style you want to set. The MDI client window does not support any special styles. Use the default styles like defined for any other control. </DL> <br><br> The following keyword arguments are recognized: <DL> <DT>hMenu <DD>the handle of a popupmenu. See remarks </DL <br><br> <b>Return value</b><br> A MDIClient instance <br> See <a HREF="../MDIClient methods/contents.html">MDIClient methods</a> for the methods supported by the MDIClient instance. <br><br> <b>Remarks</b><br> The api provides means to setup a menu keeping track of MDI childwindows. Yopu can pass the handle of a popup in the call to enable this. thre api will use the menu to reflect all relevant changes of the MDI childwindowsin the menu. If you want to insert own items into the menu you should query the <a HREF="../MDIFrame.html">MDIFrame</a> for the constant MIN_MENU_ID, defined by this class, to get the minimum allowable menu ID for user defined menu items. All IDs lower than this ID is reserved for the MDI menu. <br><br> Each MDIFrame may have only one MDIClient window </P> ::site:: MDIClient messages A MDIClient sends the following messages to the message handler:<br><br> <DL> <DT>'childcreated' <DD>a MDI childwindow has been created<br> wp=hwnd of the childwindow<br> lp=allways zero <br><br> <DT>'childdestroyed' <DD>a MDI childwindow has been destroyed<br> wp=hwnd of the childwindow<br> lp=allways zero <br><br> <DT>'childactivated' <DD>a MDI childwindow has been destroyed<br> wp=hwnd of the childwindow being activated<br> lp=hwnd of the childwindow being deactivated <br><br> <DT>'childsizing' <DD>a MDI childwindow has about to resize<br> wp=hwnd of the childwindow being resized<br> lp= tuple(x, y, w, h), containing the new dimensions of the client area <br><br> </DL> ::folder:: MDIClient methods MDIClient windows support the following methods: ::item:: onMSG <code>onMSG(hwnd, msg, wp, lp)</code><br> <P>thew message handler for the MDIClient window </P> ::item:: __iter__ <code>__iter__()</code><br> <P>Returns the hwnd of the next childwindow in turn </P> ::item:: IsChild <code>IsChild(hwnd)</code><br> <P>Retuns True if hwnd is the hwnd of a MDI childwindow of the frame, False otherwise </P> ::item:: GetChild <code>GetChild(hwnd)</code><br> <P>Wraps methods around the hwnd of a MDI childwindow. <br><br> <b>Return value</b><br> A ControlFromHandle instance. You can not subclass this instance. </P> ::item:: NewChild <code>NewChild(title, x, y, w, h, *styles, **kwargs)</code><br> <P>Creates a new MDI childwindow. <br><br> <DL> <DT>title <DD>the text that will appear in the title bar <DT>x, y, w, h <DD>the desired initial dimensions <DT>*styles <DD>one or more of the following styles: <TABLE class="table1" BORDER="1"> <TR> <TD>'maximized'</TD> <TD>the MDI child window is created initially maximized</TD> </TR> <TR> <TD></TD> <TD>the MDI child window is created initially minimized</TD> </TR> <TR> <TD>'hscroll'</TD> <TD>the MDI child window is created with a horizontal scrollbar</TD> </TR> <TR> <TD>'vscroll'</TD> <TD>the MDI child window is created with a vertical scrollbar</TD> </TR> </TABLE> </DL> <br><br> The following keyword args are recognized: <DL> <DT>icon <DD>the Icon that will appeasr in the title bar. The icon is released in the call so you can not use it any longer. </DL> <b>Return value</b><br> A ControlFromHandle instance wrapping the hwnd of the new MDI childwindow </P> ::item:: Activate <code>Activate(hwnd)</code><br> <P>Activates the MDI childwindow </P> ::item:: GetActive <code>GetActive()</code><br> <P>Returns the hwnd of the currently active MDI child </P> ::item:: ActivateNext <code>ActivateNext(hwnd=None)</code><br> <P>Activates the next MDI childwindow. <br><br> If hwnd is None the next window being activated is the window emidiately following the currently active window </P> ::item:: ActivatePrevious <code>ActivatePrevious(hwnd=None)</code><br> <P>Activates the previous MDI childwindow. <br><br> If hwnd is None the previous window being activated is the window emidiately preceeding the currently active window </P> ::item:: Destroy <code>Destroy(hwnd)</code><br> <P>Destroys a MDI childwindow <br><br> You should not this method to destroy a childwindow, and avoid using the childwindow instances 'Close' method. </P> ::item:: Clear <code>Clear()</code><br> <P>Destroys all MDI childwindows, clearing the MDIClient window </P> ::item:: Maximize <code>Maximize(hwnd)</code><br> <P>Maximizes the MDI childwindow </P> ::item:: IsMaximized <code>IsMaximized(hwnd)</code><br> <P>Returns True if the MDI childwindow is maximized, False otherwise </P> ::item:: Minimize <code>Minimize(hwnd)</code><br> <P>Minimizes the MDI childwindow </P> ::item:: IsMinimized <code>IsMinimized(hwnd)</code><br> <P>Returns True if the MDI childwindow is minimized, False otherwise </P> ::item:: Restore <code>Restore(hwnd)</code><br> <P>Restores a MDI childwindow from maximized or minimized state </P> ::item:: Cascade <code>Cascade(skipdisabled=True)</code><br> <P>Cascades all MDI childwindows. <br><br> If 'skipdisabled' is True, disabled windows are skipped </P> ::item:: Tile <code>Tile(flag='vertical')</code><br> <P>Tiles all MDI childwindows. <br><br> 'flag' can be 'vertical' to tile the childwindows vertically or 'horizontal' to tile them horizontally </P> ::item:: IconArrange <code>IconArrange()</code><br> <P>Aranges all icons of all minimized MDI childwindows </P> |