FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour window styles
Posts: 1392
Joined: Mon May 14, 2007 09:49 AM
window styles
Posted: Mon Jun 16, 2008 06:19 PM

Hi all !
I want set styles for window as WS_EX_CLIENTEDGE. I found this style in Borland\BCC55\Include\winuser.h
How I can use this file in my programm

Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
window styles
Posted: Mon Jun 16, 2008 06:47 PM

Natter,

You may use the clause STYLE:

DEFINE WINDOW oWnd STYLE nOr( WS_OVERLAPPEDWINDOW, WS_EX_CLIENTEDGE )

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
window styles
Posted: Mon Jun 16, 2008 06:52 PM

Better do it this way, as it is an extended style:

define GWL_EXSTYLE (-20)

SetWindowLong( oWnd:hWnd, GWL_EXSTYLE, WS_EX_CLIENTEDGE )

or

SetWindowLong( oWnd:hWnd, GWL_EXSTYLE, nOr( GetWindowLong( oWnd:hWnd, GWL_EXSTYLE ), WS_EX_CLIENTEDGE ) )

to keep the previous extended style too

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 1392
Joined: Mon May 14, 2007 09:49 AM
window styles
Posted: Mon Jun 16, 2008 07:32 PM

Thank, Antonio ! I do it. But I get error

"Variable WS_EX_CLIENTEDGE not found"

I must insert #INCLUDE *.ch to my program for description this WS_EX_
variables, but I found this in Winuser.h only

Posts: 4840
Joined: Fri Nov 18, 2005 04:52 PM
window styles
Posted: Mon Jun 16, 2008 08:22 PM

>I must insert #INCLUDE *.ch to my program for description this WS_EX_
variables, but I found this in Winuser.h only

You have found the proper solution. This manifest constant is a Windows API value.

FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
Posts: 1392
Joined: Mon May 14, 2007 09:49 AM
window styles
Posted: Mon Jun 16, 2008 08:49 PM

All right. How I can compiling Winuser.h together my programm.

Posts: 4840
Joined: Fri Nov 18, 2005 04:52 PM
window styles
Posted: Mon Jun 16, 2008 09:08 PM

Put this at the top of your PRG.

include "winuser.h"

FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
Posts: 1392
Joined: Mon May 14, 2007 09:49 AM
window styles
Posted: Mon Jun 16, 2008 10:34 PM

include "winuser.h" - it's not work. Created file My.h with WS_EX_ variables. That is work !

Thank all !

Posts: 811
Joined: Tue May 06, 2008 04:28 AM
window styles
Posted: Tue Jun 17, 2008 04:42 AM

Natter,

I used this

...
ON INIT ownd:oWndClient:ClientEdge()

..

Kind Regards,

Frances



Fivewin for xHarbour v18.07

xHarbour v1.2.3.x

BCC 7.3 + PellesC8 ( Resource Compiler only)

ADS 10.1 / MariaDB

Crystal Reports 8.5/9.23 DE

xMate v1.15
Posts: 1392
Joined: Mon May 14, 2007 09:49 AM
window styles
Posted: Tue Jun 17, 2008 09:23 AM

Thank, Fraxzi !
I work with external applications and change styles their different windows interactive.

Posts: 4840
Joined: Fri Nov 18, 2005 04:52 PM
window styles
Posted: Tue Jun 17, 2008 07:07 PM

Natter,

>#include "winuser.h" - it's not work.

This was probably because your PATH needed to be SET so the compiler could find it. Or, you could copy winuser.h to the application source directory.

James

FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
Posts: 1392
Joined: Mon May 14, 2007 09:49 AM
window styles
Posted: Tue Jun 17, 2008 07:48 PM

PATH is right
Well, I copy winuser.h to the application source directory

set #include "winuser.h" to my programm and compiled

see file Clip.log

winuser.h(11) Error E0024 Error in #pragma
winuser.h(38) Error F0028 Can't open #include file: 'stdarg.h'

and etc.

Posts: 4840
Joined: Fri Nov 18, 2005 04:52 PM
window styles
Posted: Tue Jun 17, 2008 08:10 PM

Natter,

OK, it seems like it also wants another file.

Try this instead. Instead of putting #include "winuser.h" do this:

define WS_EX_CLIENTEDGE 512

That should solve it.

James

FWH 18.05/xHarbour 1.2.3/BCC7/Windows 10
Posts: 1392
Joined: Mon May 14, 2007 09:49 AM
window styles
Posted: Tue Jun 17, 2008 08:37 PM

Yes, I do it. You know the others value ?

define WS_EX_ABSPOSITION ­

define WS_EX_ACCEPTFILES

define WS_EX_CLIENTEDGE 512

define WS_EX_CONTEXTHELP

define WS_EX_CONTROLPARENT

define WS_EX_DLGMODALFRAME

define WS_EX_LEFT

define WS_EX_LEFTSCROLLBAR­

define WS_EX_LTRREADING

define WS_EX_MDICHILD

define WS_EX_NOPARENTNOTIFY

define WS_EX_RIGHT

define WS_EX_RIGHTSCROLLBAR­

define WS_EX_RTLREADING

define WS_EX_SMCAPTION

define WS_EX_STATICEDGE

define WS_EX_TOOLWINDOW

define WS_EX_TOPMOST

define WS_EX_TRANSPARENT

define WS_EX_WINDOWEDGE

define WS_EX_OVERLAPPEDWINDOW

define WS_EX_PALETTEWINDOW

Continue the discussion