transparent on a say

Post Reply
User avatar
Silvio.Falconi
Posts: 4956
Joined: Thu Oct 18, 2012 7:17 pm

transparent on a say

Post by Silvio.Falconi »

I haven't used resources for a long time but tonight I was forced to create a small dialogue but being old and having signs of early senility,
I don't remember exactly how transparency was assigned to the controls say
I made
REDEFINE SAY oSaySearch[1] Prompt "Cognome" ID 4001 OF oItem:oDlgChild COLOR CLR_BLUE, GetSysColor( 15 )
REDEFINE SAY oSaySearch[1] Prompt "Nome" ID 4002 OF oItem:oDlgChild COLOR CLR_BLUE, GetSysColor( 15 )

oSaySearch[1]:lTransparent:=.t.
oSaySearch[2]:lTransparent:=.t.


why make error ?
I use : FiveWin for Harbour August 2020 (Revision) - Harbour 3.2.0dev (r1712141320) - Bcc7.30 - xMate ver. 1.15.3 - PellesC
User avatar
Rick Lipkin
Posts: 2397
Joined: Fri Oct 07, 2005 1:50 pm
Location: Columbia, South Carolina USA

Re: transparent on a say

Post by Rick Lipkin »

Silvo

I use gradient backgrounds and the SetDlgGradient() sets the global transparent variable

This is how I color my dialogue boxes .. I have many different colors I have defined as functions .. here is just a Light Grey gradient .. an added feature of the SetGradient() function is it sets the Global transparent flag .. all your text says are transparent by default using SetDLgGradient() fundtion .. no need to add Transparent to your dialogues anymore.

Code: Select all

//------------------
Func LightGreyGrad()

SetDlgGradient( { { .50, nRGB( 216, 216, 216 ), nRGB( 255, 255, 255 ) } } )

Return(nil)
 
Rick Lipkin
User avatar
Silvio.Falconi
Posts: 4956
Joined: Thu Oct 18, 2012 7:17 pm

Re: transparent on a say

Post by Silvio.Falconi »

Sorry rick,
I asked transparency of a say

I not have dialog with gradient

I use a particolar method SetDialog( cResName ) of C5 Vtaskbar, do you Know it ?

it insert a resource dialog into a menuitem with oBrush (color oThis:nClrPane)

if I insert a say then make not trasparency

Image


now I resolved set color of say with CLR_BLUE, GetSysColor( 15 ) But I think is wrong
I use : FiveWin for Harbour August 2020 (Revision) - Harbour 3.2.0dev (r1712141320) - Bcc7.30 - xMate ver. 1.15.3 - PellesC
User avatar
nageswaragunupudi
Posts: 8017
Joined: Sun Nov 19, 2006 5:22 am
Location: India
Contact:

Re: transparent on a say

Post by nageswaragunupudi »

now I resolved set color of say with CLR_BLUE, GetSysColor( 15 ) But I think is wrong
Not wrong. This is also one way. Better is COLOR CLR_BLUE, oDlg:nClrPane.
But this works only when the dialog has a plain background color.

Say ..with lTransparent := .t. should work.
Regards

G. N. Rao.
Hyderabad, India
User avatar
Silvio.Falconi
Posts: 4956
Joined: Thu Oct 18, 2012 7:17 pm

Re: transparent on a say

Post by Silvio.Falconi »

> Say ..with lTransparent := .t. should work.
here made error

Error occurred at: 12-04-2020, 19:05:46
Error description: Error BASE/1005 Variabile non disponibile: LTRANSPARENT
Args:
[ 1] = U
[ 2] = L .T.

Stack Calls
===========
Called from: => _LTRANSPARENT( 0 )
Called from: Source\spiaggia\PSpiaggia.prg => VTASKBARBEACH( 557 )


Code: Select all

REDEFINE SAY oSaySearch[1] Prompt "Cognome"  ID 4001 OF oItem:oDlgChild  COLOR CLR_BLUE, GetSysColor( 15 )
        REDEFINE SAY oSaySearch[1] Prompt "Nome"     ID 4002 OF oItem:oDlgChild  COLOR CLR_BLUE, GetSysColor( 15 )
        oSaySearch[1]:lTransparent:=.t.
        oSaySearch[2]:lTransparent:=.t.

 
I use : FiveWin for Harbour August 2020 (Revision) - Harbour 3.2.0dev (r1712141320) - Bcc7.30 - xMate ver. 1.15.3 - PellesC
User avatar
karinha
Posts: 4882
Joined: Tue Dec 20, 2005 7:36 pm
Location: São Paulo - Brasil

Re: transparent on a say

Post by karinha »

And writing like that?

Code: Select all

   REDEFINE SAY oSaySearch[1] Prompt "Cognome"  ID 4001 OF oItem:oDlgChild  ;
      COLORS CLR_BLUE, GetSysColor( 15 ) TRANSPARENT

   REDEFINE SAY oSaySearch[2] Prompt "Nome"     ID 4002 OF oItem:oDlgChild  ;
      COLORS CLR_BLUE, GetSysColor( 15 ) TRANSPARENT
 
João Santos - São Paulo - Brasil
User avatar
cnavarro
Posts: 5792
Joined: Wed Feb 15, 2012 8:25 pm
Location: España

Re: transparent on a say

Post by cnavarro »

Silvio.Falconi wrote:> Say ..with lTransparent := .t. should work.
here made error

Error occurred at: 12-04-2020, 19:05:46
Error description: Error BASE/1005 Variabile non disponibile: LTRANSPARENT
Args:
[ 1] = U
[ 2] = L .T.

Stack Calls
===========
Called from: => _LTRANSPARENT( 0 )
Called from: Source\spiaggia\PSpiaggia.prg => VTASKBARBEACH( 557 )


Code: Select all

REDEFINE SAY oSaySearch[1] Prompt "Cognome"  ID 4001 OF oItem:oDlgChild  COLOR CLR_BLUE, GetSysColor( 15 )
        REDEFINE SAY oSaySearch[1] Prompt "Nome"     ID 4002 OF oItem:oDlgChild  COLOR CLR_BLUE, GetSysColor( 15 )
        oSaySearch[1]:lTransparent:=.t.
        oSaySearch[2]:lTransparent:=.t.

 
Change second object say ( you have         REDEFINE SAY oSaySearch[1] also )

Code: Select all

        REDEFINE SAY oSaySearch[ 2 ] ..................
 
C. Navarro
Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noción del tiempo
Si alguien te dice que algo no se puede hacer, recuerda que esta hablando de sus limitaciones, no de las tuyas.
User avatar
Silvio.Falconi
Posts: 4956
Joined: Thu Oct 18, 2012 7:17 pm

Re: transparent on a say

Post by Silvio.Falconi »

Oopps
I use : FiveWin for Harbour August 2020 (Revision) - Harbour 3.2.0dev (r1712141320) - Bcc7.30 - xMate ver. 1.15.3 - PellesC
Post Reply