Przemek
Przemyslaw Czerpak-2 wrote:
>
> Passing C structures as string is also bad idea.
> If we do not need support for direct updating C structure
> members at .prg level then it will be enough to introduce
> special type of GC pointer to hold all such structures with
> basic type veryfication. Below I'm attaching modified code from
> message I sent two days ago to xHGtk devel list. It address such
> problem.
>
Sounds interesting. Never thought of such preposition before.
Can you explain a bit more how we can
use this concept in real-use. I mean I must be able to
exploit returned structure from wapi_* functions on the
PRG level. If we can pass a structure and can receive
a structure and can exploit it both ways, a much better
scenario will emerge.
Right now, we do like (via xhb.lib)
typedef struct tagPD {; // pd
DWORD lStructSize;
HWND hwndOwner;
HANDLE hDevMode;
HANDLE hDevNames;
HDC hDC;
DWORD Flags;
WORD nFromPage;
WORD nToPage;
WORD nMinPage;
WORD nMaxPage;
WORD nCopies;
HINSTANCE hInstance;
DWORD lCustData;
LPPRINTHOOKPROC lpfnPrintHook;
LPSETUPHOOKPROC lpfnSetupHook;
LPCTSTR lpPrintTemplateName;
LPCTSTR lpSetupTemplateName;
HANDLE hPrintTemplate;
HANDLE hSetupTemplate;
} PRINTDLG
Method PrintIt()
::pd IS PRINTDLG
::pd:Reset()
::pd:lStructSize := ::pd:sizeof
::pd:Flags := PD_RETURNDC + PD_SHOWHELP + PD_PRINTSETUP
::pd:nCopies := ::nCopies
if WApi_PrintDlg( ::pd:value )
::pd:Devalue()
endif
::hDC := ::pd:hDC
...
Can we achieve this type of functionality?
Regards
Pritpal Bedi
--
View this message in context:
http://www.nabble.com/SF.net-SVN%3A-harbour-project%3A-10164--trunk-harbour-tp21821360p21853693.html
Sent from the Harbour - Dev mailing list archive at Nabble.com.
_______________________________________________
Harbour mailing list
[email protected]
http://lists.harbour-project.org/mailman/listinfo/harbour