FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin para Harbour/xHarbour Nuevo FWH 25.09
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Nuevo FWH 25.09
Posted: Thu Sep 18, 2008 08:15 PM
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Nuevo FWH 19.09
Posted: Tue May 30, 2017 09:28 AM

.

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 1710
Joined: Tue Oct 28, 2008 06:26 PM
Re: Nuevo FWH 18.01
Posted: Fri Mar 02, 2018 07:37 PM
Estimado Antonio

Puede agregar 茅sta l铆nea en la Clase Btnbmp
Code (fw): Select all Collapse
METHOD MouseLeave( nRow, nCol, nFlags ) CLASS TBtnBmp
    
   ::lMOver = .F.
   XEval( ::bMMoved, ::lMOver )
   ::Setcolor( CLR_BLACK )  //脡sta
   ::Refresh()

return nil


Gracias
Saludos,



Adhemar C.
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Nuevo FWH 18.01
Posted: Sat Mar 03, 2018 08:26 AM

Adhemar,

Se cambia el color del texto del bot贸n en caso de no hacerlo ?

Por qu茅 cambia el color ?

Deber铆a seguir us谩ndose el valor contenido en ::nClrText

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 1710
Joined: Tue Oct 28, 2008 06:26 PM
Re: Nuevo FWH 18.01
Posted: Mon Mar 05, 2018 12:38 PM
Estimado Antonio
Hago lo siguiente:
Code (fw): Select all Collapse
聽If lPuede 聽//Bot贸n activo
聽 聽 聽 聽REDEFINE BTNBMP oBtn ID xI+100 OF oDlgMnu RESOURCE "Boton1",Nil,Nil,"Boton2" PROMPT oMenu:Item ACTION (&aAct,oDlgMnu:SetFocus()) FONT oFontMenu TRANSPARENT ADJUST 2007
聽 聽 聽 聽oBtn:bMMoved:= {|| lColor:=.t.,cMsg:=vMsg,BusFoto(vTab,xI), oMsg:Refresh(),oBtn:Setcolor( CLR_HBLUE )}
聽 聽 Else ////Bot贸n Desactivado
聽 聽 聽 聽REDEFINE BTNBMP oBtn ID xI+100 OF oDlgMnu RESOURCE "Boton1",Nil,Nil,"Boton1" PROMPT oMenu:Item FONT oFontMenu TRANSPARENT ADJUST 2007
聽 聽 聽 聽oBtn:SetColor( CLR_GRAY )
聽 聽 聽 聽oBtn:bMMoved:= {|| lColor:=.F.,cMsg:=vMsg,BusFoto(vTab,xI), oMsg:Refresh(),oBtn:Setcolor( CLR_GRAY )}
聽 聽 ENDif


Modifiqu茅 la clase as铆
Code (fw): Select all Collapse
METHOD MouseLeave( nRow, nCol, nFlags ) CLASS TBtnBmp
聽 聽 
聽 聽::lMOver = .F.
聽 聽XEval( ::bMMoved, ::lMOver )
聽 聽If lColor 聽 //Para controlar cuando el bot贸n est谩 desactivado y no se ponga 聽CLR_BLACK
聽 聽 聽::Setcolor( CLR_BLACK ) 聽
聽 聽Endif
聽 聽::Refresh()
return nil

https://ibb.co/nMjQTS
https://ibb.co/g2txa7
https://ibb.co/gcCR2n


C贸mo podr铆a hacer para no modificar la clase

Muchas gracias por la ayuda.
Saludos,



Adhemar C.
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: Nuevo FWH 18.01
Posted: Mon Mar 05, 2018 02:17 PM
Possible that you can simplify the code with something similar to this:
Code (fw): Select all Collapse
REDEFINE BTNBMP oBtn ID xI+100 OF oDlgMnu RESOURCE "Boton1",Nil,Nil,"Boton2" ;
PROMPT oMenu:Item ACTION (&aAct,oDlgMnu:SetFocus()) 
COLOR { |lMOver| If( lMover, CLR_BLUE, CLR_BLACK ) }, CLR_WHITE ;
FONT oFontMenu TRANSPARENT ADJUST 2007

if !lPuede
   oBtn:Disable()
endif

If the button is disabled the text color is always GRAY.
If the button is active when the mouse is over the text color is BLUE and when the mouse is away the text color is black.
You may not need to use bMMoved block
Regards



G. N. Rao.

Hyderabad, India
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: Nuevo FWH 18.01
Posted: Mon Mar 05, 2018 02:19 PM
This example can be used to test
Code (fw): Select all Collapse
#include "fivewin.ch"

function Main()

   local oDlg, oFont, oBtn1, oBtn2

   DEFINE FONT oFont NAME "TAHOMA" SIZE 0,-14 BOLD

   DEFINE DIALOG oDlg SIZE 400,300 PIXEL TRUEPIXEL FONT oFont

   @ 020,20 BTNBMP oBtn1 SIZE 200,70 PIXEL OF oDlg ;
      FILE "\fwh\bitmaps\32x32\cascade.bmp", nil, nil, ;
           "\fwh\bitmaps\32x32\tiled.bmp" ;
      PROMPT "Prompt" 2007 ;
      COLOR { |lMOver| If( lMover, CLR_HRED, CLR_BLACK ) }, CLR_WHITE ;
      ACTION MsgInfo( "Some Action" ) ;
      MESSAGE "MouseOver"

   @ 120,20 BTNBMP oBtn2 SIZE 200,70 PIXEL OF oDlg ;
      FILE "\fwh\bitmaps\32x32\cascade.bmp", nil, nil, ;
           "\fwh\bitmaps\32x32\tiled.bmp" ;
      PROMPT "Prompt" 2007 ;
      COLOR { |lMOver| If( lMover, CLR_HRED, CLR_BLACK ) }, CLR_WHITE ;
      ACTION MsgInfo( "Some Action" ) ;
      MESSAGE "MouseOver"

   oBtn2:Disable()

   oDlg:bInit  := <||
         DEFINE MSGBAR OF oDlg PROMPT "" 2007
         return nil
         >

   ACTIVATE DIALOG oDlg CENTERED

   RELEASE FONT oFont

return nil
Regards



G. N. Rao.

Hyderabad, India
Posts: 1710
Joined: Tue Oct 28, 2008 06:26 PM
Re: Nuevo FWH 18.01
Posted: Mon Mar 05, 2018 07:39 PM
Thanks Mr. Rao

Compiling this gives this error: D:\Sistemas\RRHH\DATA\PRG\RRHH.PRG(230) Error E0030 Syntax error "syntax error at 'BTNBMP'"

Code (fw): Select all Collapse
REDEFINE BTNBMP oBtn ID xI+100 OF oDlgMnu RESOURCE "Boton1",Nil,Nil,"Boton2" ;
PROMPT oMenu:Item ACTION (&aAct,oDlgMnu:SetFocus()) ;
COLOR { |lMOver| If( lMover, CLR_BLUE, CLR_BLACK ) }, CLR_WHITE ;
FONT oFontMenu TRANSPARENT ADJUST 2007

Without the COLOR line, compile OK

The example compiles ok maybe it's because of the resource
Saludos,



Adhemar C.
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: Nuevo FWH 18.01
Posted: Mon Mar 05, 2018 10:21 PM
Code (fw): Select all Collapse
REDEFINE BTNBMP oBtn ID xI+100 OF oDlgMnu RESOURCE "Boton1",Nil,Nil,"Boton2" ;
PROMPT oMenu:Item ACTION (&aAct,oDlgMnu:SetFocus()) 
FONT oFontMenu TRANSPARENT ADJUST 2007

oBtn:nClrText := { |lMOver| If( lMover, CLR_BLUE, CLR_BLACK ) }

if !lPuede
   oBtn:Disable()
endif
Regards



G. N. Rao.

Hyderabad, India
Posts: 1710
Joined: Tue Oct 28, 2008 06:26 PM
Re: Nuevo FWH 18.01
Posted: Mon Mar 05, 2018 10:43 PM

Perfect!!

Thank you very much

Saludos,



Adhemar C.
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Nuevo FWH 18.05
Posted: Sun Jul 22, 2018 05:03 PM

FWH 18.05 revised build 1

viewtopic.php?p=213759#p213759

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: Nuevo FWH 18.11
Posted: Sat Dec 01, 2018 10:55 AM
regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 344
Joined: Sat Jul 22, 2006 09:04 PM
Re: Nuevo FWH 20.07
Posted: Tue Aug 11, 2020 03:02 PM
Hola buenos dias Antonio,
He probado xbrbar.prg: shows inbuilt buttonbar in xbrowse. en un ejemplo mio, y me hace el siguiente efecto al pulsar sobre la cabecera o sobre la buttonbar.
Adjunto un archivo gif para que aprecie el efecto que hace al poner

Saludos
Marcelo
FWH - Harbour - BCC7 - PellesC
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: Nuevo FWH 20.07
Posted: Wed Aug 12, 2020 03:50 AM
Yes.
This was a bug in FWH2006, fixed in FWH2007.
Whatsnew.txt
- When a column header is clicked, the header is painted in the topbar area
fixed.
viewtopic.php?f=3&t=39178&p=233785#p233785

Please let us know if you are having this problem with FWH2007 also?
Regards



G. N. Rao.

Hyderabad, India
Posts: 344
Joined: Sat Jul 22, 2006 09:04 PM
Re: Nuevo FWH 20.07
Posted: Wed Aug 12, 2020 11:43 AM

Buenos d铆as Mr. Rao, si efectivamente esto ocurri贸 en la FWH2007 es por eso que lo reporte en este hilo.
Saludos cordiales desde Argentina.

FWH - Harbour - BCC7 - PellesC