You can subscribe to this list here.
| 2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(1041) |
Sep
(746) |
Oct
(46) |
Nov
(89) |
Dec
(117) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2006 |
Jan
(21) |
Feb
(236) |
Mar
(316) |
Apr
(166) |
May
(114) |
Jun
(18) |
Jul
(23) |
Aug
(10) |
Sep
(35) |
Oct
(8) |
Nov
(44) |
Dec
(54) |
| 2007 |
Jan
(7) |
Feb
(21) |
Mar
(3) |
Apr
(1) |
May
|
Jun
(78) |
Jul
(9) |
Aug
(12) |
Sep
|
Oct
|
Nov
(1) |
Dec
|
|
From: andrew7 <bd...@us...> - 2007-02-20 14:16:28
|
Update of /cvsroot/smartwin/SmartWin/source In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv684/source Modified Files: LibraryLoader.cpp Log Message: ::GetProcAddress takes only ascii characters, so insure unicode is converted first. Index: LibraryLoader.cpp =================================================================== RCS file: /cvsroot/smartwin/SmartWin/source/LibraryLoader.cpp,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- LibraryLoader.cpp 19 Dec 2006 01:48:29 -0000 1.6 +++ LibraryLoader.cpp 20 Feb 2007 14:16:10 -0000 1.7 @@ -103,7 +103,7 @@ // Get procedure address from loaded library by name FARPROC LibraryLoader::getProcAddress( const SmartUtil::tstring & procedureName ) { - return ::GetProcAddress( itsHMod, procedureName.c_str() ); + return ::GetProcAddress( itsHMod, SmartUtil::AsciiGuaranteed::doConvert( procedureName, SmartUtil::ConversionCodepage::ANSI ).c_str() ); } // Get procedure address from loaded library by ordinal value |
|
From: andrew7 <bd...@us...> - 2007-02-19 02:59:58
|
Update of /cvsroot/smartwin/SmartWin In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv15975 Modified Files: makeSetup.bat Log Message: Version as used for RC3 Index: makeSetup.bat =================================================================== RCS file: /cvsroot/smartwin/SmartWin/makeSetup.bat,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- makeSetup.bat 19 Feb 2007 01:19:20 -0000 1.2 +++ makeSetup.bat 19 Feb 2007 02:59:54 -0000 1.3 @@ -4,15 +4,6 @@ REM Build SmartWin++ without NANT -if not exist need_to_copy_files ( -rmdir SmartWin /S /Q -mkdir ..\relSmartWin -xcopy . ..\relSmartWin /Y /E /EXCLUDE:exclude.txt -mkdir SmartWin -xcopy ..\relSmartWin SmartWin /Y /E -) - - if not exist need_to_doc_gen ( cd doxygenIn doxygen Doxyfile @@ -24,6 +15,16 @@ ) +if not exist need_to_copy_files ( +rmdir SmartWin /S /Q +mkdir ..\relSmartWin +xcopy . ..\relSmartWin /Y /E /EXCLUDE:exclude.txt +mkdir SmartWin +xcopy ..\relSmartWin SmartWin /Y /E +) + + + if not exist need_to_Inno_setup ( cd SmartWin "\Program Files\Inno Setup 5\iscc" setup.iss |
|
From: andrew7 <bd...@us...> - 2007-02-19 02:24:12
|
Update of /cvsroot/smartwin/SmartWin/tests/swDll In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv1785/tests/swDll Modified Files: swDllMain.cpp Added Files: ResourceDialogClass.h resource.h swDllswMain.cpp Log Message: Try resources in DLLs --- NEW FILE: swDllswMain.cpp --- // $Revision: 1.1 $ /* Copyright (c) 2005 - Thomas Hansen * Part of the SmartWin++ library example code * Permission to use under the same terms as the actual library * The license to the library can be found at http://smartwinlib.org * License for library is Open Source and BSD */ // swDllswMain.cpp : Defines the entry point for the C++ application. // This program uses swDll.dll whose source is swDll.cpp, and API definition is swdll.h // We use SmartWin in the application, and in the DLL. // Both projects are in the swDLL directory. // #define DLLMODE dllimport #include "swdll.h" #include <iostream> #include "SmartWin.h" using namespace SmartWin; class HelloWinClass : public WidgetFactory< WidgetWindow, HelloWinClass > { private: WidgetMenuPtr itsMainMenu; WidgetButtonPtr itsButton; public: void menuSayHello( WidgetMenuPtr menu, unsigned item ) { int numb; char str[99]; // Dll gets values with a GUI. if ( guiGetNumberAndString( & numb, ( char * ) & str ) ) { createMessageBox().show( _T( "Hello !" ), str ); } } void menuClose( WidgetMenuPtr menu, unsigned item ) { close(); } void buttonClicked( WidgetButtonPtr button ) { int numb; char str[99]; // Same thing but this time the DLL does it with a dialog. if ( dialogGetNumberAndString( & numb, ( char * ) & str ) ) { createMessageBox().show( _T( "Hello !" ), str ); } } void initAndCreate() { createWindow(); setText( _T( "Hello SmartWin" ) ); // Title SmartWin::Rectangle desktop( getDesktopSize() ); setBounds( desktop.top( 0.2 ).right( 0.3 ) ); itsButton = createButton(); itsButton->setText( _T( "Bring up a dialog from a DLL" ) ); itsButton->onClicked( & HelloWinClass::buttonClicked ); itsButton->setBounds( sw::Rectangle( Point( 200, 30 ) ) ); // Creating main menu itsMainMenu = createMenu(); WidgetMenuPtr file = itsMainMenu->appendPopup( _T( "&MenuCommands" ) ); int m = 1; file->appendItem( m++, _T( "Use DLL function" ), & HelloWinClass::menuSayHello ); file->appendItem( m++, _T( "Close" ), & HelloWinClass::menuClose ); #ifndef WINCE itsMainMenu->attach( this ); #endif layout(); onSized( & HelloWinClass::isResized ); } void isResized( const WidgetSizedEventResult & sz ) { layout(); } void layout() { SmartWin::Place p; SmartWin::Rectangle r( getClientAreaSize() ); p.setBoundsBorders( r, 4, 4 ); itsButton->setPositionPerPlace( p ); } }; int SmartWinMain( Application & app ) { HelloWinClass * testHello = new HelloWinClass; testHello->initAndCreate(); return app.run(); } --- NEW FILE: ResourceDialogClass.h --- #include "SmartWin.h" using namespace SmartWin; #include <iostream> //------------------------------------------------------- /* ResourceDialogClass IN: Class needs to be constructed with a dialog resource ID that contains: Two buttons: IDOK and IDCANCEL, and one textbox: IDC_HEXEDIT */ #include "resource.h" class ResourceDialogClass : public SmartWin::WidgetFactory< SmartWin::WidgetDialog, ResourceDialogClass, SmartWin::MessageMapPolicyDialogWidget > { private: WidgetTextBox * itsHexTxt; // or WidgetText * if using MSVC++ char * itsOutStrPtr; public: // Constructor ResourceDialogClass( char * outStrPtr ) : itsOutStrPtr( outStrPtr) { try { createDialog( IDD_HEXDIALOG ); WidgetButtonPtr btnOk = subclassButton( IDOK ); WidgetButtonPtr btnCancel = subclassButton( IDCANCEL ); itsHexTxt = subclassTextBox( IDC_HEXEDIT ); itsHexTxt->setTextLimit(32); itsHexTxt->setFocus(); itsHexTxt->setText( _T("Hello from a resource based dialog in a DLL") ); onClosing( & ResourceDialogClass::closing ); btnCancel->onClicked( & ResourceDialogClass::cancelClicked ); btnOk->onClicked( & ResourceDialogClass::OkClicked ); } catch ( xCeption x ) { SmartUtil::tstring errmsg( x.whatWndMsg() ); errmsg += _T(" from "); errmsg += x.what(); createMessageBox().show( errmsg ); } } void OkClicked( WidgetButtonPtr btn ) { close(); } void cancelClicked( WidgetButtonPtr btn ) { itsHexTxt->setText( _T("Cancel") ); } bool closing() { strcpy( itsOutStrPtr, itsHexTxt->getText().c_str() ); return true; } }; //------------------------------------------------------- --- NEW FILE: resource.h --- //{{NO_DEPENDENCIES}} // Microsoft Visual C++ generated include file. // Used by WidgetDialog.rc // #define IDD_HEXDIALOG 101 #define IDC_HEXEDIT 1001 // Next default values for new objects // #ifdef APSTUDIO_INVOKED #ifndef APSTUDIO_READONLY_SYMBOLS #define _APS_NEXT_RESOURCE_VALUE 102 #define _APS_NEXT_COMMAND_VALUE 40001 #define _APS_NEXT_CONTROL_VALUE 1002 #define _APS_NEXT_SYMED_VALUE 101 #endif #endif Index: swDllMain.cpp =================================================================== RCS file: /cvsroot/smartwin/SmartWin/tests/swDll/swDllMain.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- swDllMain.cpp 7 Jan 2007 18:43:05 -0000 1.4 +++ swDllMain.cpp 19 Feb 2007 02:24:02 -0000 1.5 @@ -1,6 +1,7 @@ // $Revision$ // swDllMain.cpp : Defines the entry point for the C++ application. // This program uses swDll.dll whose source is swDll.cpp, and API definition is swdll.h +// We don't use SmartWin in the application, but do in the DLL. // Both projects are in the swDLL directory. // #define DLLMODE dllimport |
|
From: andrew7 <bd...@us...> - 2007-02-19 02:05:22
|
Update of /cvsroot/smartwin/SmartWin In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv27309 Modified Files: exclude.txt Log Message: Remove documentation generating exes. Index: exclude.txt =================================================================== RCS file: /cvsroot/smartwin/SmartWin/exclude.txt,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- exclude.txt 19 Feb 2007 01:19:20 -0000 1.1 +++ exclude.txt 19 Feb 2007 02:05:19 -0000 1.2 @@ -14,3 +14,5 @@ .res Buildlog.htm _private +doxygen.exe +hhc.exe |
|
From: andrew7 <bd...@us...> - 2007-02-19 01:59:09
|
Update of /cvsroot/smartwin/SmartWin/tests/swDll In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv24970/tests/swDll Modified Files: make.msvc.bat Log Message: No more stdafx.cpp Index: make.msvc.bat =================================================================== RCS file: /cvsroot/smartwin/SmartWin/tests/swDll/make.msvc.bat,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- make.msvc.bat 17 Apr 2006 19:06:46 -0000 1.2 +++ make.msvc.bat 19 Feb 2007 01:59:05 -0000 1.3 @@ -1,9 +1,9 @@ :: swDll -cl -c -nologo -Zm200 -O1 -DNDEBUG -D_WINDOWS -D_USRDLL -DSWDLL_EXPORTS -D_WINDLL -MT -EHsc -GR -W0 -I"." -I"..\..\include" -I"..\..\include\smartwin" -Fo .\swDll.cpp .\stdafx.cpp +cl -c -nologo -Zm200 -O1 -DNDEBUG -D_WINDOWS -D_USRDLL -DSWDLL_EXPORTS -D_WINDLL -MT -EHsc -GR -W0 -I"." -I"..\..\include" -I"..\..\include\smartwin" -Fo .\swDll.cpp -link /NOLOGO /DLL /OPT:REF /OPT:ICF /SUBSYSTEM:WINDOWS /IMPLIB:"swDll.lib" /incremental:no /OUT:"swDll.dll" swDll.obj stdafx.obj ..\..\lib\smartwin.lib comctl32.lib user32.lib Gdi32.lib opengl32.lib glu32.lib kernel32.lib gdi32.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib uuid.lib imm32.lib comdlg32.lib Wininet.lib wsock32.lib libcmt.lib +link /NOLOGO /DLL /OPT:REF /OPT:ICF /SUBSYSTEM:WINDOWS /IMPLIB:"swDll.lib" /incremental:no /OUT:"swDll.dll" swDll.obj ..\..\lib\smartwin.lib comctl32.lib user32.lib Gdi32.lib opengl32.lib glu32.lib kernel32.lib gdi32.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib uuid.lib imm32.lib comdlg32.lib Wininet.lib wsock32.lib libcmt.lib :: swDllMain @@ -13,5 +13,5 @@ link /NOLOGO /SUBSYSTEM:CONSOLE /incremental:no /OUT:"main-msvc.exe" swDllMain.obj ..\..\lib\smartwin.lib swDll.lib comctl32.lib user32.lib Gdi32.lib opengl32.lib glu32.lib kernel32.lib gdi32.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib uuid.lib imm32.lib comdlg32.lib Wininet.lib wsock32.lib -rm -f *.obj +del /Q *.obj |
|
From: andrew7 <bd...@us...> - 2007-02-19 01:55:48
|
Update of /cvsroot/smartwin/SmartWin/tests/PocketPC/SmartWinDevicesUnitTests/SampleWidgets In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv23601/tests/PocketPC/SmartWinDevicesUnitTests/SampleWidgets Modified Files: make.msvc.bat Log Message: Use del instead of rm Index: make.msvc.bat =================================================================== RCS file: /cvsroot/smartwin/SmartWin/tests/PocketPC/SmartWinDevicesUnitTests/SampleWidgets/make.msvc.bat,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- make.msvc.bat 17 Apr 2006 19:06:45 -0000 1.6 +++ make.msvc.bat 19 Feb 2007 01:55:45 -0000 1.7 @@ -1,9 +1,7 @@ -if not exist mkdir obj - rc -i"..\..\.." -dDS_FIXEDSYS=0x0008L -dLANG_ENGLISH=0x09 -dSUBLANG_ENGLISH_US=0x01 -dSUBLANG_ENGLISH_UK=0x02 -dSUBLANG_NORWEGIAN_BOKMAL=0x01 -dLANG_NORWEGIAN=0x14 -fo SampleWidgets.res SampleWidgets.rc cl -c -nologo -Zm200 -O1 -DNDEBUG -MT -EHsc -GR -W0 -I"." -I"..\..\..\..\include" -I"..\..\..\..\include\smartwin" -Fo Buttons.cpp DataGrid.cpp Main.cpp Mainwindow.cpp Misc.cpp Sliders.cpp TabSheetWidget.cpp link /NOLOGO /SUBSYSTEM:WINDOWS /incremental:no /OUT:"main-msvc.exe" Buttons.obj DataGrid.obj Main.obj Mainwindow.obj Misc.obj Sliders.obj TabSheetWidget.obj SampleWidgets.res ..\..\..\..\lib\smartwin.lib comctl32.lib user32.lib Gdi32.lib opengl32.lib glu32.lib kernel32.lib gdi32.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib uuid.lib imm32.lib comdlg32.lib Wininet.lib wsock32.lib -rm -f *.obj +del /Q *.obj |
|
From: andrew7 <bd...@us...> - 2007-02-19 01:48:53
|
Update of /cvsroot/smartwin/SmartWin/tests In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv20775/tests Modified Files: make.msvc.4all Log Message: Use del instead of rm Index: make.msvc.4all =================================================================== RCS file: /cvsroot/smartwin/SmartWin/tests/make.msvc.4all,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- make.msvc.4all 17 Apr 2006 19:06:45 -0000 1.6 +++ make.msvc.4all 19 Feb 2007 01:48:50 -0000 1.7 @@ -3,4 +3,4 @@ link /NOLOGO /SUBSYSTEM:WINDOWS /incremental:no /OUT:"main-msvc.exe" Main.obj ..\..\lib\smartwin.lib ..\..\lib\SmartSOAP.lib comctl32.lib user32.lib Gdi32.lib opengl32.lib glu32.lib kernel32.lib gdi32.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib uuid.lib imm32.lib comdlg32.lib Wininet.lib wsock32.lib -rm -f *.obj +del /Q *.obj |
|
From: andrew7 <bd...@us...> - 2007-02-19 01:22:22
|
Update of /cvsroot/smartwin/SmartWin/doxygenIn/html In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv10250/doxygenIn/html Modified Files: msvc71.html Log Message: Add mixed unicode and mbs bug description Index: msvc71.html =================================================================== RCS file: /cvsroot/smartwin/SmartWin/doxygenIn/html/msvc71.html,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- msvc71.html 30 Nov 2006 00:31:20 -0000 1.6 +++ msvc71.html 19 Feb 2007 01:22:19 -0000 1.7 @@ -78,11 +78,10 @@ <h4>Runtime Errors </h4> <li> - Unhandled exception at 0x7c59bc3f in pivtest.exe: Microsoft C++ exception: - bad_cast @ 0x0012e82c. + Exception CreateWindowEx in Widget::create fizzled <br> - One source: You have a widget under a tab, and you did not do a - "widg->setEventHandler( this );".</li> + One source: You linked with a multibyte Smartwin lib, but have a unicode program. + (It makes the Windows class names not match) </ul> |
|
From: andrew7 <bd...@us...> - 2007-02-19 01:20:35
|
Update of /cvsroot/smartwin/SmartWin In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv9809 Modified Files: makeSetup.build Log Message: Copy jpg files over also. Index: makeSetup.build =================================================================== RCS file: /cvsroot/smartwin/SmartWin/makeSetup.build,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- makeSetup.build 23 Jul 2006 20:10:51 -0000 1.7 +++ makeSetup.build 19 Feb 2007 01:20:31 -0000 1.8 @@ -67,6 +67,7 @@ <include name="**/*.rc" /> <include name="**/*.ico" /> <include name="**/*.bmp" /> + <include name="**/*.jpg" /> <include name="**/*.cur" /> <include name="**/*.resx" /> <include name="**/*.asax" /> |
|
From: andrew7 <bd...@us...> - 2007-02-19 01:19:26
|
Update of /cvsroot/smartwin/SmartWin In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv9350 Modified Files: ReadMe.txt makeSetup.bat Added Files: exclude.txt Log Message: Non nant build Index: makeSetup.bat =================================================================== RCS file: /cvsroot/smartwin/SmartWin/makeSetup.bat,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- makeSetup.bat 25 Oct 2005 11:22:40 -0000 1.1 +++ makeSetup.bat 19 Feb 2007 01:19:20 -0000 1.2 @@ -1 +1,37 @@ -nant -buildfile:makeSetup.build \ No newline at end of file +nant -buildfile:makeSetup.build +if not errorlevel 1 exit + +REM Build SmartWin++ without NANT + + +if not exist need_to_copy_files ( +rmdir SmartWin /S /Q +mkdir ..\relSmartWin +xcopy . ..\relSmartWin /Y /E /EXCLUDE:exclude.txt +mkdir SmartWin +xcopy ..\relSmartWin SmartWin /Y /E +) + + +if not exist need_to_doc_gen ( +cd doxygenIn +doxygen Doxyfile +hhc ..\doxygenOut\doc\index.hhp +mkdir ..\docs +copy ..\doxygenOut\doc\index.chm ..\docs +copy ..\doxygenOut\doc\index.chi ..\docs +cd .. +) + + +if not exist need_to_Inno_setup ( +cd SmartWin +"\Program Files\Inno Setup 5\iscc" setup.iss +cd .. +) + + +echo off +REM Where to get tools. +REM http://msdn.microsoft.com/library/default.asp?url=/library/en-us/htmlhelp/html/hwMicrosoftHTMLHelpDownloads.asp +REM http://www.jrsoftware.org/isinfo.php Index: ReadMe.txt =================================================================== RCS file: /cvsroot/smartwin/SmartWin/ReadMe.txt,v retrieving revision 1.14 retrieving revision 1.15 diff -u -d -r1.14 -r1.15 --- ReadMe.txt 16 Jan 2007 14:25:29 -0000 1.14 +++ ReadMe.txt 19 Feb 2007 01:19:20 -0000 1.15 @@ -139,4 +139,11 @@ __GNUC__ + - Building releases of SmartWin++ + makeSetup.bat builds SmartWin++, which calls makeSetup.build. + This requires nant. + + + + --- NEW FILE: exclude.txt --- \doxygenOut\ \cvs\ .exe .dll .a .obj .o .lib .ncb .ilk .idb .pdb .dep .res Buildlog.htm _private |
|
From: andrew7 <bd...@us...> - 2007-02-18 15:07:26
|
Update of /cvsroot/smartwin/SmartWin/tests/WidgetStatic In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv18227/tests/WidgetStatic Modified Files: Main.cpp Log Message: Do an UpdateWidget after you change the color, and resizing won't give the multicolor effect. Index: Main.cpp =================================================================== RCS file: /cvsroot/smartwin/SmartWin/tests/WidgetStatic/Main.cpp,v retrieving revision 1.13 retrieving revision 1.14 diff -u -d -r1.13 -r1.14 --- Main.cpp 23 Jun 2006 22:38:14 -0000 1.13 +++ Main.cpp 18 Feb 2007 15:07:22 -0000 1.14 @@ -4,8 +4,6 @@ \brief Unit test for WidgetStatic It tries to instantiate all different forms of WidgetStatic and it also tries to use all functions. - - TODO: If you resize quicly the window, the static control doesn't repaint completely ... */ #include "SmartWin.h" @@ -22,6 +20,11 @@ WidgetTest1() {} + void clicked( WidgetStaticPtr stat ) + { + setColors(); + } + void dblClicked( WidgetStaticPtr stat ) { createMessageBox().show( SmartUtil::tstring( _T( "Static Widget double clicked : " ) ) + stat->getText() ); @@ -47,36 +50,58 @@ createWindow( windowCS ); onTextChanging( & WidgetTest1::textChanged ); + onSized( & WidgetTest1::isResized ); + WidgetStatic::Seed staticCs; staticCs.caption = _T( "Initial text will be changed to test handler." ); staticCs.font = createFont( _T( "Times New Roman" ), 0, 10, 1, ANSI_CHARSET, true, false, false, 0, OUT_DEFAULT_PRECIS ); staticCs.location = SmartWin::Rectangle( getClientAreaSize() ).shrink( 50l ); - WidgetStaticPtr stat = createStatic( staticCs ); + stat = createStatic( staticCs ); srand( ( unsigned ) time( NULL ) ); stat->onBackgroundColor( & WidgetTest1::backgroundColor ); stat->onTextChanging( & WidgetTest1::textChanged ); stat->onDblClicked( & WidgetTest1::dblClicked ); + stat->onClicked( & WidgetTest1::clicked ); - stat->setText( _T( "Testing static control ... \nthe background and the font color will change...\nTry resizing the window quicly" ) ); + stat->setText( _T( "Click to change the background and the font color." ) ); //some compile tests and get/set symmetry test stat->setBounds( staticCs.location, false ); assert( stat->getBounds().pos == staticCs.location.pos && stat->getBounds().size == staticCs.location.size ); assert( stat->getPosition() == staticCs.location.pos ); assert( stat->getSize() == staticCs.location.size ); + + setColors(); } - BrushPtr bgBrush; + void isResized( const WidgetSizedEventResult & sz ) + { + + } + + void setColors() + { + itsBackgroundColor= RGB( rand()%255, rand()%255, rand()%255 ); + itsTextColor= RGB( rand()%255, rand()%255, rand()%255 ); + stat->updateWidget(); + } + boost::shared_ptr< sw::Brush > backgroundColor( WidgetStaticPtr stat, SmartWin::Canvas & canvas ) { - // tranparent background for text + // transparent background for text canvas.setBkMode( true ); - SetTextColor( canvas.getDc(), RGB( rand()%255, rand()%255, rand()%255 ) ); - bgBrush = boost::shared_ptr< sw::Brush >( new SmartWin::Brush( canvas, RGB( rand()%255, rand()%255, rand()%255 ) ) ); + SetTextColor( canvas.getDc(), itsTextColor ); + bgBrush = boost::shared_ptr< sw::Brush >( new SmartWin::Brush( canvas, itsBackgroundColor ) ); return bgBrush; } + +private: + WidgetStaticPtr stat; + COLORREF itsBackgroundColor, itsTextColor; + BrushPtr bgBrush; + }; int SmartWinMain( Application & app ) |
|
From: andrew7 <bd...@us...> - 2007-02-18 14:35:24
|
Update of /cvsroot/smartwin/SmartWin/tests/WidgetDialog In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv6242/tests/WidgetDialog Modified Files: Main.cpp Log Message: Unicode _T() Index: Main.cpp =================================================================== RCS file: /cvsroot/smartwin/SmartWin/tests/WidgetDialog/Main.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- Main.cpp 15 Oct 2006 14:35:29 -0000 1.1 +++ Main.cpp 18 Feb 2007 14:35:20 -0000 1.2 @@ -30,6 +30,7 @@ #include "SmartWin.h" using namespace SmartWin; +#include <iostream> //------------------------------------------------------- /* HexDialog @@ -47,7 +48,7 @@ : public SmartWin::WidgetFactory< SmartWin::WidgetDialog, HexDialog<ParentClass>, SmartWin::MessageMapPolicyDialogWidget > { private: - WidgetTextBoxPtr itsHexTxt; + typename HexDialog<ParentClass>::WidgetTextBox * itsHexTxt; // or WidgetText * if using MSVC++ ParentClass * itsParent; public: @@ -57,11 +58,12 @@ : Widget( main ), itsParent( main ) { - createDialog( iddDialog ); + this->createDialog( iddDialog ); - WidgetButtonPtr btnOk = subclassButton( IDOK ); - WidgetButtonPtr btnCancel = subclassButton( IDCANCEL ); - itsHexTxt = subclassTextBox( IDC_HEXEDIT ); + typename HexDialog<ParentClass>::WidgetButton *btnOk = this->subclassButton( IDOK ); +// WidgetButtonPtr btnOk = subclassButton( IDOK ); + typename HexDialog<ParentClass>::WidgetButtonPtr btnCancel = this->subclassButton( IDCANCEL ); + itsHexTxt = this->subclassTextBox( IDC_HEXEDIT ); itsHexTxt->setTextLimit(32); itsHexTxt->setFocus(); itsHexTxt->setText( label ); @@ -71,13 +73,13 @@ btnOk->onClicked( & HexDialog::OkClicked ); } -void OkClicked( WidgetButtonPtr btn ) +void OkClicked( typename HexDialog<ParentClass>::WidgetButtonPtr btn ) { itsParent->dataFromDialog( itsHexTxt->getText() ); } -void cancelClicked( WidgetButtonPtr btn ) +void cancelClicked( typename HexDialog<ParentClass>::WidgetButtonPtr btn ) { itsParent->dataFromDialog( _T( "Cancel" ) ); } @@ -132,17 +134,20 @@ itsTabSheet->setButtonStyle( false ); itsTabSheet->setHotTrack(); - std::stringstream ss; + + SmartUtil::tstringstream ss; + for ( int i=0; i < 5; i++ ) { - ss << "Page " << i; + ss << _T("Page ") << i; itsTabSheet->addPage( ss.str(), i ); ss.str( "" ); - ss << "Dialog " << i; + ss << _T("Dialog ") << i; itsHexDialogs.push_back( new HexDialog<DialogTestClass>( this, ss.str(), IDD_HEXDIALOG ) ); - ss.str( "" ); + ss.str( _T("") ); itsHexDialogs[i]->setVisible( false ); } + itsLastSelectedIndex= 0; itsHexDialogs[itsLastSelectedIndex]->setVisible( true ); |
|
From: andrew7 <bd...@us...> - 2007-02-18 14:20:48
|
Update of /cvsroot/smartwin/SmartWin/tests/WidgetComboBox In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv793/tests/WidgetComboBox Modified Files: Main.cpp Log Message: Add combo box with choices always displayed. Index: Main.cpp =================================================================== RCS file: /cvsroot/smartwin/SmartWin/tests/WidgetComboBox/Main.cpp,v retrieving revision 1.10 retrieving revision 1.11 diff -u -d -r1.10 -r1.11 --- Main.cpp 11 Dec 2006 23:54:03 -0000 1.10 +++ Main.cpp 18 Feb 2007 14:20:44 -0000 1.11 @@ -1,9 +1,9 @@ // $Revision$ /*! \file Main.cpp - \brief Unit test for WidgetTextBox. + \brief Unit test for WidgetComboBox. - It tries to instantiate all different forms of WidgetTextBox and it also tries to use all functions. + It tries to instantiate all different forms of WidgetComboBox and it also tries to use all functions. */ #include "SmartWin.h" @@ -37,9 +37,9 @@ windowCS.caption = _T( "WidgetComboBox compile and execute test" ); createWindow( windowCS ); + // Combo box. WidgetComboBox::Seed widgetComboBoxCS; - - widgetComboBoxCS.location = SmartWin::Rectangle( 50, 50, 200, 400 ); + widgetComboBoxCS.location = SmartWin::Rectangle( 20, 50, 120, 400 ); WidgetComboBoxPtr comboBox = createComboBox( widgetComboBoxCS ); @@ -62,8 +62,9 @@ comboBox->onSelectionChanged( & WidgetTest1::selectionChanged ); + // Combo box that is disabled WidgetComboBoxPtr comboBox2 = createComboBox(); - comboBox2->setBounds( SmartWin::Point( 100, 100 ), SmartWin::Point( 200, 400 ) ); + comboBox2->setBounds( SmartWin::Point( 20, 100 ), SmartWin::Point( 120, 400 ) ); comboBox2->addValue( _T( "Disabled Value1" ) ); comboBox2->addValue( _T( "Disabled Value2" ) ); comboBox2->addValue( _T( "Disabled Value3" ) ); @@ -75,6 +76,20 @@ comboBox2->setEnabled( false ); assert( !comboBox2->getEnabled() ); + + // Combo box with the choices always displayed + WidgetComboBox::Seed listBoxSeed; + listBoxSeed.location = SmartWin::Rectangle( 160, 50, 100, 100 ); + listBoxSeed.style = WS_CHILD | WS_VISIBLE | CBS_SIMPLE | CBS_HASSTRINGS | WS_VSCROLL; + + WidgetComboBoxPtr listBox = createComboBox( listBoxSeed ); + listBox->addValue( _T( "Value5" ) ); + listBox->removeAllItems(); + listBox->addValue( _T( "Value1" ) ); + listBox->addValue( _T( "Value2" ) ); + listBox->addValue( _T( "Value3" ) ); + listBox->addValue( _T( "Value4" ) ); + comboBox->setFocus(); } }; @@ -85,7 +100,7 @@ WidgetTest1 * testWnd1 = new WidgetTest1; testWnd1->initAndCreate(); WidgetTest1::WidgetComboBox * freeBox = testWnd1->createComboBox(); - freeBox->setBounds( 150, 150, 100, 100 ); + freeBox->setBounds( 20, 150, 100, 100 ); freeBox->addValue( _T( "TestingFree1" ) ); freeBox->addValue( _T( "TestingFree2" ) ); freeBox->setVisible( false ); |
|
From: andrew7 <bd...@us...> - 2007-02-18 01:01:37
|
Update of /cvsroot/smartwin/SmartWin/tests/HelloSmartWin In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv1774/tests/HelloSmartWin Modified Files: hello.cpp Log Message: Show Place's TabTo function, and how to do old style listboxes. Index: hello.cpp =================================================================== RCS file: /cvsroot/smartwin/SmartWin/tests/HelloSmartWin/hello.cpp,v retrieving revision 1.25 retrieving revision 1.26 diff -u -d -r1.25 -r1.26 --- hello.cpp 20 Apr 2006 05:03:39 -0000 1.25 +++ hello.cpp 18 Feb 2007 01:01:33 -0000 1.26 @@ -69,7 +69,7 @@ WidgetButtonPtr itsButton; WidgetCheckBoxPtr itsCheckBox; WidgetComboBoxPtr itsComboBox; - WidgetDataGridPtr itsList; + WidgetDataGridPtr itsGrid, itsList; WidgetGroupBoxPtr itsRadioGroupBox; WidgetRadioButtonPtr itsRadios[ ITEMS ]; WidgetTextBoxPtr itsTextBoxSource; @@ -139,6 +139,7 @@ itsTree->setFont( choosenFont ); itsComboBox->setFont( choosenFont ); + itsGrid->setFont( choosenFont ); itsList->setFont( choosenFont ); itsRadioGroupBox->setFont( choosenFont ); for ( int i = 0; i < ITEMS; i++ ) itsRadios[ i ] ->setFont( choosenFont ); @@ -247,6 +248,7 @@ createMessageBox().show( _T( "New selection: " ) + comboBox->getSelectedValue() ); } + void treeNodeSelChanged( WidgetTreeViewPtr tree ) { SmartUtil::tstring itemText = tree->getSelectedItemText(); @@ -362,16 +364,29 @@ itsComboBox->setSelectedIndex( 2 ); itsComboBox->onSelectionChanged( & HelloWinClass::selectionChanged ); - // List or grid Widget - itsList = itsMulti->createDataGrid(); + // List Widget + std::vector< SmartUtil::tstring > listColumn, listValue; + listColumn.push_back( _T("Column") ); + WidgetDataGrid::Seed listSeed= WidgetDataGrid::getDefaultSeed(); + listSeed.style |= LVS_NOCOLUMNHEADER; + itsList= itsMulti->createDataGrid( listSeed ); + itsList->createColumns( listColumn ); + listValue.push_back( _T("Zero") ); itsList->insertRow( listValue ); + listValue[0]= _T("One"); itsList->insertRow( listValue ); + listValue[0]= _T("Two"); itsList->insertRow( listValue ); + itsList->onSelectionChanged( & HelloWinClass::listSelChanged ); + + + // grid Widget + itsGrid = itsMulti->createDataGrid(); std::vector< SmartUtil::tstring > columns; for ( int i = 0; i < colN; i++ ) columns.push_back( cols[ i ] ); - itsList->createColumns( columns ); + itsGrid->createColumns( columns ); std::vector< SmartUtil::tstring > values; for ( int i = 0; i < labN; i++ ) values.push_back( labels[ i ] ); - itsList->insertRow( values ); - itsList->insertRow( values ); + itsGrid->insertRow( values ); + itsGrid->insertRow( values ); // Creating tree view itsTree = itsMulti->createTreeView(); @@ -387,9 +402,18 @@ for ( int i = 0; i < colN; i++ ) itsTree->insertNode( labels[ i ], root, i ); } + + void listSelChanged( WidgetDataGridPtr grid ) + { + itsComboBox->setSelectedIndex( grid->getSelectedIndex() ); + } + + void initAndCreate() { - createWindow(); + // createWindow(); + createInvisibleWindow(); + setText( _T( "Hello SmartWin" ) ); // Title SmartWin::Rectangle desktop( getDesktopSize() ); @@ -432,6 +456,7 @@ createSingleItems(); onPainting( & HelloWinClass::painting ); + onKeyPressed( & HelloWinClass::keyPressed ); layout(); // for the first time, and only AFTER all Widgets are created. onSized( & HelloWinClass::isResized ); @@ -439,6 +464,7 @@ // Since tab sheet will hide underlaying controls we need to position it at the BOTTOM of the Z-order window chain ::SetWindowPos( itsTabSheet->handle(), HWND_BOTTOM, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE ); updateWidget(); + setVisible( true ); } void isResized( const WidgetSizedEventResult & sz ) @@ -539,6 +565,8 @@ p.positionToRight( pos_size ); itsHorizSlider->setBounds( pos_size ); + p.tabTo( 0.5 ); // Move over to the 50% mark + // These two will have enough size to fit their text in the current font. itsCheckBox->setSizePerTextPerPlace( p, itsCheckBox->getText(), 40, 4 ); itsButton->setSizePerTextPerPlace( p, itsButton->getText(), 40, 4 ); @@ -559,6 +587,7 @@ p.setBoundsBorders( rect, 6, 8 ); // X, Y border between Widgets int rows = 2, cols = 3; // For sizing purposes, we divide into a grid. + itsComboBox->setSizeAsGridPerPlace( p, rows, cols ); itsTree->setSizeAsGridPerPlace( p, rows, cols ); @@ -579,15 +608,24 @@ itsRadios[ rowdex ] ->setSizeAsCol( radio1inside, radiorows, rowdex ); } + itsList->setSizeAsGridPerPlace( p, rows, cols ); + // List Grid takes the rest ... SmartWin::Rectangle ListGridRect; p.sizeForRemainingSpace( ListGridRect ); - itsList->setBounds( ListGridRect ); + itsGrid->setBounds( ListGridRect ); } itsMulti->setVisible( isVisible ); } + bool keyPressed( int key ) + { + char c= virtualKeyToChar(key); + return true; + } + + void painting( Canvas & pc ) { paint( pc ); |
|
From: andrew7 <bd...@us...> - 2007-02-18 01:00:15
|
Update of /cvsroot/smartwin/SmartWin/tests/Canvas In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv968/tests/Canvas Modified Files: canvas_all.cpp Log Message: Demonstrate how to use Gdiplus::Bitmap Index: canvas_all.cpp =================================================================== RCS file: /cvsroot/smartwin/SmartWin/tests/Canvas/canvas_all.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- canvas_all.cpp 30 Nov 2006 00:57:12 -0000 1.11 +++ canvas_all.cpp 18 Feb 2007 01:00:10 -0000 1.12 @@ -23,7 +23,7 @@ #include "encircle.h" // Remove the comment part below to use GdiPlus and view an Image in addition to the other cool stuff you see... ;) -// #define UseGdiPlus 1 +#define UseGdiPlus 1 #ifdef UseGdiPlus #include <gdiplus.h> using namespace Gdiplus; @@ -113,6 +113,10 @@ void painting( SmartWin::Canvas & c ) { + // BufferedCanvas< Canvas > c( this->handle() ); + + + // rc.pos is the upper left point, rc.size is the lower right point. SmartWin::Rectangle rc( getClientAreaSize() ); RECT kokko = rc; @@ -222,6 +226,7 @@ // Draw a JPG file using Window's GDI classes. GdiPlus( c.getDc(), 0, y, x2, y + yinc ); // GDI+ Logic #endif + // c.blast( rc ); } #ifdef UseGdiPlus @@ -235,8 +240,18 @@ Image image( L"sample.jpg" ); graphics.DrawImage( & image, x, y ); + + int width= 20, height= 30; + Gdiplus::Bitmap checker( width, height, &graphics ); + for ( int w=0; w < width; w += 2 ) { + for ( int h=0; h < height; h += 4 ) { + checker.SetPixel( w, h, Color( 255, 0, 0, 255 ) ); + } + } + graphics.DrawImage( & checker, x+image.GetWidth(), y ); } #endif + // There are new dimensions to the window because the user resized the window. void isResized( const SmartWin::WidgetSizedEventResult & sz ) { @@ -363,6 +378,7 @@ // Application entry point just like all other SmartWin applications... int SmartWinMain( Application & app ) { - CanvasWidget * cw = new CanvasWidget(); cw->init(); + CanvasWidget * cw = new CanvasWidget(); + cw->init(); return ( app.run() ); } |
|
From: andrew7 <bd...@us...> - 2007-02-18 00:55:47
|
Update of /cvsroot/smartwin/SmartWin/include/smartwin In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv31890/include/smartwin Modified Files: Place.h Log Message: Add working tabTo function. Index: Place.h =================================================================== RCS file: /cvsroot/smartwin/SmartWin/include/smartwin/Place.h,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- Place.h 5 May 2006 17:14:37 -0000 1.8 +++ Place.h 18 Feb 2007 00:55:44 -0000 1.9 @@ -162,7 +162,7 @@ */ void tabTo( double xfract ) { - itsPos.x = itsLowRight.x + ( long )( xfract * ( itsLowRight.x - itsUpLeft.x ) ); + itsPos.x = itsUpLeft.x + ( long )( xfract * ( itsLowRight.x - itsUpLeft.x ) ); } /// Sets obj.pos to the current position, and updates the position by obj.size. |
|
From: andrew7 <bd...@us...> - 2007-02-18 00:47:24
|
Update of /cvsroot/smartwin/SmartWin/include/io In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv28748/include/io Modified Files: iolib.h Log Message: Add vectToFile Index: iolib.h =================================================================== RCS file: /cvsroot/smartwin/SmartWin/include/io/iolib.h,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- iolib.h 10 Dec 2006 22:24:50 -0000 1.12 +++ iolib.h 18 Feb 2007 00:47:16 -0000 1.13 @@ -175,6 +175,27 @@ return( true ); } + +//--------------------- + +static bool vectToFile( const SmartUtil::tstring & filePath, vector<unsigned char> dat ) +{ + if ( 0 == filePath.size() != 0 ) return( false ); + + + basic_ofstream< TCHAR > file( SmartUtil::AsciiGuaranteed::doConvert( filePath.c_str(), + SmartUtil::ConversionCodepage::UTF8 ).c_str(), + ios_base::binary ); + if ( ! file.good() ) return( false ); + + for( unsigned int i=0; i < dat.size(); i++ ) { + file.put( dat[i] ); + } + + return( true ); +} + + //------------------------------------------------------------------------- static bool print( SmartUtil::tstring & printtext ) |
|
From: andrew7 <bd...@us...> - 2007-02-18 00:45:55
|
Update of /cvsroot/smartwin/SmartWin In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv27996 Modified Files: SmartWin.dev Log Message: Index: SmartWin.dev =================================================================== RCS file: /cvsroot/smartwin/SmartWin/SmartWin.dev,v retrieving revision 1.21 retrieving revision 1.22 diff -u -d -r1.21 -r1.22 --- SmartWin.dev 20 Apr 2006 09:49:39 -0000 1.21 +++ SmartWin.dev 18 Feb 2007 00:45:52 -0000 1.22 @@ -1,7 +1,7 @@ [Project] FileName=SmartWin.dev Name=SmartWin -UnitCount=111 +UnitCount=116 Type=2 Ver=1 ObjFiles= @@ -1018,9 +1018,9 @@ BuildCmd= [Unit112] -FileName=Widgets\WidgetProgressBar.h +FileName=include\io\iolib.h CompileCpp=1 -Folder=Widgets +Folder=Header Compile=1 Link=1 Priority=1000 @@ -1197,3 +1197,43 @@ OverrideBuildCmd=0 BuildCmd= +[Unit113] +FileName=include\io\html_get.h +CompileCpp=1 +Folder=Header +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit114] +FileName=include\io\html_put.h +CompileCpp=1 +Folder=Header +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit115] +FileName=include\io\InDialog.h +CompileCpp=1 +Folder=Header +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + +[Unit116] +FileName=include\io\InDialogClasses.h +CompileCpp=1 +Folder=Header +Compile=1 +Link=1 +Priority=1000 +OverrideBuildCmd=0 +BuildCmd= + |
|
From: andrew7 <bd...@us...> - 2007-02-18 00:40:59
|
Update of /cvsroot/smartwin/SmartWin/source In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv26061/source Modified Files: Application.cpp Log Message: Allow wince to still work with one hInst for all. Index: Application.cpp =================================================================== RCS file: /cvsroot/smartwin/SmartWin/source/Application.cpp,v retrieving revision 1.44 retrieving revision 1.45 diff -u -d -r1.44 -r1.45 --- Application.cpp 7 Jan 2007 18:44:33 -0000 1.44 +++ Application.cpp 18 Feb 2007 00:40:54 -0000 1.45 @@ -258,6 +258,12 @@ } } +// Purpose is to generate a unique class name. +// If you have application with DLLs, there will be multiple instances, and +// multiple Application instances. +// except for WinCE, which used only one hInst for all. +// So we need an approach for WinCE that put the application handle in. +// void Application::generateLocalClassName( Seed & x_Seed ) { static unsigned int d_CurrentNo = 0; @@ -265,7 +271,11 @@ static Utilities::CriticalSection cs; Utilities::ThreadLock tmpLock( cs ); - d_ClassName << _T( "SW_" ) << d_CurrentNo++; +#ifdef WINCE + d_ClassName << _T( "SW_" ) << Application::instance().getAppHandle() << d_CurrentNo++; +#else + d_ClassName << _T( "SW_" ) << d_CurrentNo++; +#endif x_Seed.className = d_ClassName.str(); } |
|
From: andrew7 <bd...@us...> - 2007-01-16 14:27:25
|
Update of /cvsroot/smartwin/SmartWin/doxygenIn/html In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv25968/doxygenIn/html Modified Files: devcpp.html Log Message: Improve instructions for building the library in Dev-C++ Index: devcpp.html =================================================================== RCS file: /cvsroot/smartwin/SmartWin/doxygenIn/html/devcpp.html,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- devcpp.html 12 Oct 2005 19:03:33 -0000 1.5 +++ devcpp.html 16 Jan 2007 14:27:11 -0000 1.6 @@ -16,33 +16,34 @@ basic installation. Compile and run from the Execute menu. <br> </P> - <P>Open the libsmartwin.dev project, and Execute | rebuild all.</P> - <P>A libsmartwin.a file will appear in the /lib subdirectory.</P> - <P> </P> - <H3>Build a SmartWin++ sample from the tests directory. - </H3> - <P>Open any .dev file (I tried Notepad) from the SmartWin++ unit tests projects.</P> - <P>Execute | compile and run . You should get the SmartWin++ Notepad running !</P> - <P> </P> - <H3>Create a new SmartWin++ program. - </H3> + <H3> Build the SmartWin library. </H3> + <P> Use Dev-C++'s "File | Open Project" menu option to open the SmartWin.dev project, + and then "Execute | rebuild all".<b></b> + A libsmartwin.a file will appear in the /lib subdirectory. + </P> + <P></P> + <H3>Build a SmartWin++ sample from the tests directory. </H3> + <P>Open any .dev file (I tried Notepad) from the SmartWin++ unit tests projects. <br></br> + Execute | compile and run . You should get the SmartWin++ Notepad running !</P> + <P></P> + <H3>Create a new SmartWin++ program.</H3> <P>File | New | Project, select a Windows application, C++ Project, and name - it. Choose a directory. Discard the boilerplate windows main.cpp, and + it. Choose a directory. Discard the boilerplate windows main.cpp, and write your own SmartWin++ program.</P> - <P> Right click on the project, Project Options, and choose Directories | - Include Directories. Use the filesystem icon to insert the include + <P> Right click on the project, Project Options, and choose Directories | + Include Directories. Use the filesystem icon to insert the include directory that has SmartWin.h, then click on Add.</P> - <P>From Project Options, Parameters, use Add library or Object and select the - libsmartwin.a. Enter "-lcomctl32" in the linker box on the next + <P>From Project Options, Parameters, use Add library or Object and select the + libsmartwin.a. Enter "-lcomctl32" in the linker box on the next line.</P> <P>Execute | Compile & Run should now build your program and run it.</P> <P>(Or it may be easier to simply copy an existing .dev file, rename it, and textedit the differences for your new project.)</P> - <P> </P> - <P> </P> + <P></P> + <P></P> <H3>Configure DEV-CPP for SmartWin++ </H3> - <P>(No longer needed with the .dev files included with SmartWin++ 1.0 )</P> + <P>(No longer needed with the .dev files included with SmartWin++ 1.0 )</P> <P>Tools | Compiler Options | Directories | C++ includes , and browse for the SmartWin++ directory.</P> <P>(The little File icon to the right of the blank line.) Then click Add, and then |
|
From: andrew7 <bd...@us...> - 2007-01-16 14:25:33
|
Update of /cvsroot/smartwin/SmartWin In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv25149 Modified Files: ReadMe.txt Log Message: Add reference to compiler specific info in doxygen\html Index: ReadMe.txt =================================================================== RCS file: /cvsroot/smartwin/SmartWin/ReadMe.txt,v retrieving revision 1.13 retrieving revision 1.14 diff -u -d -r1.13 -r1.14 --- ReadMe.txt 22 Dec 2005 19:43:01 -0000 1.13 +++ ReadMe.txt 16 Jan 2007 14:25:29 -0000 1.14 @@ -23,7 +23,9 @@ include directory path in which the SmartWin.h file resides and also add the library directory path where SmartWin.lib/SmartWin.a is found. Consult your compiler documentation or go to http://smartwin.sourceforge.net/ to find out how to do this - for the most commonly-used compilers. + for the most commonly-used compilers. There is also compiler specific documentation + in the doxygenIn\html directory. + - Licensing The license for using SmartWin++ is in the same folder as this ReadMe file and @@ -87,6 +89,7 @@ The doxygenIn directory holds extra images and html files used to produce the Doxygen documentation. The doxygenOut\doc directory holds the output of the generation of Doxygen documentation. + See the doxygenIn\Readme.txt for instructions. The lib directory gets the .lib or .o files after the source is compiled and linked. |
|
From: andrew7 <bd...@us...> - 2007-01-16 13:44:14
|
Update of /cvsroot/smartwin/SmartWin/doxygenIn/html In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv7730/doxygenIn/html Modified Files: msvcToolkit.html Log Message: Hint for new projects Index: msvcToolkit.html =================================================================== RCS file: /cvsroot/smartwin/SmartWin/doxygenIn/html/msvcToolkit.html,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- msvcToolkit.html 9 Apr 2006 15:23:29 -0000 1.2 +++ msvcToolkit.html 16 Jan 2007 13:44:08 -0000 1.3 @@ -64,6 +64,13 @@ <P></P> </li> </ul> + <p> + When creating a new project, you may need to set the VS Express project property Linker | System | SubSystem to Windows, <br> + and C++ | Code Generation from "dll" to multi-threaded and multi-threaded debug. + </p> + + + <br> <br> <H2>Microsoft Visual Studio 6 |
|
From: andrew7 <bd...@us...> - 2007-01-07 18:53:15
|
Update of /cvsroot/smartwin/SmartWin/include/smartwin/widgets In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv8474/include/smartwin/widgets Modified Files: WidgetDialog.h Log Message: Add exception if CreateDialogParam fails. Index: WidgetDialog.h =================================================================== RCS file: /cvsroot/smartwin/SmartWin/include/smartwin/widgets/WidgetDialog.h,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- WidgetDialog.h 5 May 2006 17:14:42 -0000 1.11 +++ WidgetDialog.h 7 Jan 2007 18:53:12 -0000 1.12 @@ -84,6 +84,12 @@ ( this->Widget::itsParent ? this->Widget::itsParent->handle() : 0 ), ( WidgetWindowBase< EventHandlerClass, SmartWin::MessageMapPolicyModalDialogWidget >::mainWndProc_ ), reinterpret_cast< LPARAM >( boost::polymorphic_cast< Widget * >( this ) ) ); + + if ( !this->Widget::itsHandle ) { + xCeption x( _T( "CreateDialogParam failed." ) ); + throw x; + } + Widget::registerWidget(); } |
|
From: andrew7 <bd...@us...> - 2007-01-07 18:45:16
|
Update of /cvsroot/smartwin/SmartWin/include/smartwin In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv5242/include/smartwin Modified Files: Application.h Log Message: Allow resource based dialogs in a DLL: Add hInstance param to neededSWinit Index: Application.h =================================================================== RCS file: /cvsroot/smartwin/SmartWin/include/smartwin/Application.h,v retrieving revision 1.19 retrieving revision 1.20 diff -u -d -r1.19 -r1.20 --- Application.h 18 Aug 2006 19:08:10 -0000 1.19 +++ Application.h 7 Jan 2007 18:45:08 -0000 1.20 @@ -52,6 +52,7 @@ #endif #endif +/// Contains all classes used in SmartWin namespace SmartWin { // begin namespace SmartWin @@ -115,6 +116,7 @@ LPSTR lpCmdLine, int nCmdShow ); #endif + friend class Widget; friend class MessageMapPolicyModalDialogWidget; friend std::list < Widget * > & private_::getApplicationWidgets(); @@ -168,7 +170,7 @@ /// The initialization that must be done first. /** Used internally by the WinMain function, and externally for DLL initialization. */ - static void neededSmartWinInit(); + static void neededSmartWinInit( HINSTANCE hInstance, int nCmdShow, const char * cmdLine ); /// Calls various leak and memory corruption routines. /** Used after the message loop completes in WinMain. |
|
From: andrew7 <bd...@us...> - 2007-01-07 18:44:36
|
Update of /cvsroot/smartwin/SmartWin/source In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv4956/source Modified Files: Application.cpp Log Message: Allow resource based dialogs in a DLL: Add hInstance param to neededSWinit Index: Application.cpp =================================================================== RCS file: /cvsroot/smartwin/SmartWin/source/Application.cpp,v retrieving revision 1.43 retrieving revision 1.44 diff -u -d -r1.43 -r1.44 --- Application.cpp 16 Dec 2006 15:48:51 -0000 1.43 +++ Application.cpp 7 Jan 2007 18:44:33 -0000 1.44 @@ -43,6 +43,8 @@ #endif //! WINCE #endif //! _MSC_VER +// Friend functions to Application + std::list < Widget * > & private_::getApplicationWidgets() { return Application::itsInstance->itsWidgets; @@ -73,15 +75,15 @@ unsigned int retVal = 0; bool corruptMemMemLeak = false; - Application::neededSmartWinInit(); - try - { #ifndef WINCE - std::string cmdLineString = lpCmdLine; + std::string cmdLineString = lpCmdLine; #else - std::string cmdLineString = SmartUtil::AsciiGuaranteed::doConvert( lpCmdLine, SmartUtil::ConversionCodepage::ANSI ); + std::string cmdLineString = SmartUtil::AsciiGuaranteed::doConvert( lpCmdLine, SmartUtil::ConversionCodepage::ANSI ); #endif - Application::Instantiate( hInstance, nCmdShow, cmdLineString.c_str() ); + + Application::neededSmartWinInit( hInstance, nCmdShow, cmdLineString.c_str() ); + try + { retVal = SmartWinMain( Application::instance() ); // Call library user's startup function. Application::UnInstantiate(); @@ -94,10 +96,16 @@ return retVal; } + +// Application implementation + /** Initializes the runtime for SmartWin++ + Typically only called by WinMain or DllMain. */ - void Application::neededSmartWinInit() + void Application::neededSmartWinInit( HINSTANCE hInstance, int nCmdShow, const char * cmdLine ) { + Application::Instantiate( hInstance, nCmdShow, cmdLine ); + #ifndef WINCE BOOL enable; ::SystemParametersInfo( SPI_GETUIEFFECTS, 0, & enable, 0 ); |