Fivewin Uxtheme

Fivewin Uxtheme

Postby Jimmy » Sat Oct 29, 2022 7:35 am

hi,

as TFolder() seems not to use "visual Style" i search for uxtheme
now i found in fwh\source\function\c5cnew.c some HB_FUNC()

when search under \classes i found only
\fwh\source\classes\btnbmp.prg

which use "OpenThemeData"

so only Type "BUTTON" have Theme :?:

---

how to "Set" Theme under Fivewin for TFolder() :?:
Code: Select all  Expand view
  ::hTheme := @UxTheme:OpenThemeData( 0, Str2Unicode( "Tab" ) + CHR( 0 ) )
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1732
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Re: Fivewin Uxtheme

Postby Antonio Linares » Sat Oct 29, 2022 10:42 am

Jimmy,

Please try it this way:

C5_OpenThemeData( oTabs:hWnd, "SysTabControl32" )
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Fivewin Uxtheme

Postby Jimmy » Sat Oct 29, 2022 10:38 pm

hi Antonio,
Antonio Linares wrote:Please try it this way:
C5_OpenThemeData( oTabs:hWnd, "SysTabControl32" )

thx for Answer

as i can say "Name" for Theme come from TMSCHEMA.H
"Button"
"Rebar"
"Toolbar"
"Status"
"Menu"
"ListView"
"Progress"
"Tab"
"Trackbar"
"Tooltips"
"TreeView"
"Spin"
"Page"
"Scrollbar"
"Edit"
"ComboBox"
"Taskbar Clock"
"Tray Notify"
"TaskBar"
"TaskBand"
"StartPanel"
"ExplorerBar"
"TaskBand"

but only "Button" is used and all other Controls have no "visual Style" under Fivewin :?:

---

as also "other C5_*" Function also are need like C5_DrawThemeBackground() for Control, so i need to re-write Control if i want to use "visual Style"

missing (for Ownerdraw)
IsThemeBackgroundPartiallyTransparent()
DrawThemeParentBackground()

Code: Select all  Expand view
        nRet := @UxTheme:IsThemeBackgroundPartiallyTransparent(::hTheme, BP_PUSHBUTTON, iStateId)
         IF .NOT. EMPTY(nRet)
            nRet := @UxTheme:DrawThemeParentBackground(::hButton,::oDrawItemStruct:hDC, ::oDrawItemStruct:rcItem)
         ENDIF

         nRet := @UxTheme:DrawThemeBackground(::hTheme,;
                       ::oDrawItemStruct:hDC   ,;
                       BP_PUSHBUTTON           ,;
                       iStateId                ,;
                       ::oDrawItemStruct:rcItem,;
                       0 )
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1732
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Re: Fivewin Uxtheme

Postby Enrico Maria Giordano » Sun Oct 30, 2022 7:32 am

Jimmy wrote:but only "Button" is used and all other Controls have no "visual Style" under Fivewin :?:


Can I see a sample of a controls without "visual style" and the same with "visual style"?
User avatar
Enrico Maria Giordano
 
Posts: 8715
Joined: Thu Oct 06, 2005 8:17 pm
Location: Roma - Italia

Re: Fivewin Uxtheme

Postby Jimmy » Sun Oct 30, 2022 10:20 am

hi Enrico,
Enrico Maria Giordano wrote:Can I see a sample of a controls without "visual style" and the same with "visual style"?

a Button get "other" Style when Manifest is "enable", that you can "see"
but what about "hover" ( when Mouse is over Control but not click ) when have no Manifest or not "enable" :?:

Visual Style for "PUSHBUTTON are
Code: Select all  Expand view
BEGIN_TM_PART_STATES(PUSHBUTTON)
     TM_STATE(1, PBS, NORMAL)
     TM_STATE(2, PBS, HOT)
     TM_STATE(3, PBS, PRESSED)
     TM_STATE(4, PBS, DISABLED)
     TM_STATE(5, PBS, DEFAULTED)
END_TM_PART_STATES()

so it is more as only "look like" when it is "in Action"
have a look into TMSCHEMA.H where every Control have those Constant to "ask" when Mouse move or click
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1732
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Re: Fivewin Uxtheme

Postby Antonio Linares » Sun Oct 30, 2022 8:15 pm

Dear Jimmy,

Could you please post some screenshots ?

many thanks
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Fivewin Uxtheme

Postby Jimmy » Mon Oct 31, 2022 4:56 am

hi Antonio,
Antonio Linares wrote:Could you please post some screenshots ?

i can only talk about Controls which i have used until now ... and that are not much

---

CLASS TFolder() is the latest Control where i notice that it does not show "Hot" Style when "hover"

btw. TFolderEx() seems not documented in Help File
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1732
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany

Re: Fivewin Uxtheme

Postby Antonio Linares » Mon Oct 31, 2022 7:17 am

Dear Jimmy,

> CLASS TFolder() is the latest Control where i notice that it does not show "Hot" Style when "hover"

Could you please post a screenshot, using another GUIs, of such "Hot" Style when "hover" ?

Class TFolderEx was a usar (Daniel Garcia Gil) contribution to FWH and its quite similar to the Windows standard "folder", but with extras (colors on tabs, etc)
regards, saludos

Antonio Linares
www.fivetechsoft.com
User avatar
Antonio Linares
Site Admin
 
Posts: 42099
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain

Re: Fivewin Uxtheme

Postby Jimmy » Thu Nov 03, 2022 1:37 pm

hi Antonio,

as i say i just have use "some" Control so i can´t say "more"

---
have search in Source for
InitCommonControlsEx / InitCCEx / InitCommon() / InitCommonControls()

which seems used by

CLASS TReBar() / CLASS TToolBar()
CLASS TCalendar() / CLASS TDatePick() / Class TTimePick()

and Listview Header which have ICC_* Setting
https://learn.microsoft.com/en-us/windows/win32/api/commctrl/ns-commctrl-initcommoncontrolsex

as i know each Control have own ICC_* Constant which belong to Constant in TMSCHEMA.H
greeting,
Jimmy
User avatar
Jimmy
 
Posts: 1732
Joined: Thu Sep 05, 2019 5:32 am
Location: Hamburg, Germany


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Google [Bot] and 66 guests