FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin para Harbour/xHarbour problema con xbrowse y Grid (SOLUCIONADO)
Posts: 694
Joined: Fri Oct 07, 2005 06:58 AM
problema con xbrowse y Grid (SOLUCIONADO)
Posted: Tue Aug 30, 2022 10:21 AM
Tengo un xbrowse con colores en degradado y al moverve con los cursores no limpia bien las celdas. (haciendo click con el ratón en otra fila sí actualiza las filas bien)

Se quedan restos por debajo de la celda del color amarillo y verde.



He modificado el ejemplo /Samples/xbwser.prg
Code (fw): Select all Collapse
function fSetUp( oBrw, aHead )
  local nI

   for nI = 1 to len( aHead )
      oBrw:aCols[ nI ]:cHeader   = aHead[ nI ]
   next

   //oBrw:bClrStd := {|| {CLR_BLACK, iif( oBrw:nArrayAt() % 2 = 0, CLR_HCYAN, CLR_LIGHTGRAY  ) } }
   oBrw:bClrStd          := { || if( oBrw:nArrayAt() % 2 == 0, { CLR_BLACK, nRGB(186, 224, 191) }, { CLR_BLACK, nRGB(214, 237, 215)} ) } 
   oBrw:bClrSelFocus     := { || { CLR_BLACK, { { .5, nRgb(128, 128, 0), nRGB(255,255,193) }, { .5, nRGB(255,255,193), nRgb(128, 128, 0) } }} }
   oBrw:bClrRowFocus     := { || { CLR_BLACK, { { .5, CLR_WHITE, nRgb(255, 217, 93) } } } }    
   
   oBrw:oWnd:aControls[ BUTTON_PRINT ]:cCaption := "My Text"
   oBrw:oWnd:aControls[ BUTTON_PRINT ]:bAction := {|| msginfo( "My Action" ) }

   oBrw:oWnd:aControls[ BUTTON_SHEET ]:cCaption := "Notepad"
   oBrw:oWnd:aControls[ BUTTON_SHEET ]:bAction := {|| winexec( "Notepad.exe") }

return nil
Un saludo

Fernando González Diez

ALSIS Sistemas Informáticos
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: problema con xbrowse y Grid.
Posted: Tue Aug 30, 2022 10:27 AM

Fernando,

El Sr. Rao lo va a revisar ya que él es el mantenedor de la Clase TXBrowse

gracias por reportarlo

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 866
Joined: Tue Oct 16, 2007 08:57 AM
Re: problema con xbrowse y Grid.
Posted: Tue Aug 30, 2022 11:28 AM
Antonio Linares wrote:Fernando,

El Sr. Rao lo va a revisar ya que él es el mantenedor de la Clase TXBrowse

gracias por reportarlo


Dear Antonio,

Same as my problem. But no any answer for it.

http://forums.fivetechsupport.com/viewtopic.php?f=3&t=41983&sid=03f9d927ce2d8747bb610a38cb326610
Best Regards,



Richard



Harbour 3.2.0dev (r2503251254) => Borland C++ v7.7 32bit

MySQL v8.0

Harbour 3.2.0dev (r2503251254) => Borland C++ v7.7 64bit
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: problema con xbrowse y Grid.
Posted: Tue Aug 30, 2022 02:14 PM
Please add one more setting:
Code (fw): Select all Collapse
oBrw:lFullPaint := .t.
Regards



G. N. Rao.

Hyderabad, India
Posts: 694
Joined: Fri Oct 07, 2005 06:58 AM
Re: problema con xbrowse y Grid.
Posted: Wed Aug 31, 2022 08:09 AM

Hola,

con lFullPaint, se soluciona el problema del pintado.

Pero si el browse tiene muchas columnas en pantalla, se ralentiza mucho el movimiento con los cursores hacia arriba y hacia abajo.

Un saludo

Fernando González Diez

ALSIS Sistemas Informáticos
Posts: 44158
Joined: Thu Oct 06, 2005 05:47 PM
Re: problema con xbrowse y Grid.
Posted: Wed Aug 31, 2022 03:06 PM

Fernando,

El Sr. Rao me comentó ayer que esto es una solución temporal y que se pone manos a la obra para solucionarlo correctamente

Démosle tiempo para poder hacerlo :-)

un abrazo

regards, saludos

Antonio Linares
www.fivetechsoft.com
Posts: 866
Joined: Tue Oct 16, 2007 08:57 AM
Re: problema con xbrowse y Grid.
Posted: Wed Aug 31, 2022 04:53 PM
Antonio Linares wrote:Fernando,

El Sr. Rao me comentó ayer que esto es una solución temporal y que se pone manos a la obra para solucionarlo correctamente

Démosle tiempo para poder hacerlo :-)

un abrazo


Ok. Waiting for it.
Best Regards,



Richard



Harbour 3.2.0dev (r2503251254) => Borland C++ v7.7 32bit

MySQL v8.0

Harbour 3.2.0dev (r2503251254) => Borland C++ v7.7 64bit
Posts: 694
Joined: Fri Oct 07, 2005 06:58 AM
Re: problema con xbrowse y Grid.
Posted: Wed Aug 31, 2022 08:32 PM

Ok.

Encantado de poder esperar.

Un saludo

Fernando González Diez

ALSIS Sistemas Informáticos
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: problema con xbrowse y Grid.
Posted: Fri Sep 02, 2022 12:24 PM
Can you both please help me by testing this fix?

In the program
fwh\source\function\imgtxtio.prg,
function GradientFill(...)

Please locate these lines of code:
Code (fw): Select all Collapse
   if lVert
      nSize    := nBottom - nTop + 1

      for nClr := 1 to nClrs

         nSlice = If( nClr == nClrs, nBottom, ;
                     Min( nBottom, nTop + nSize * aGradInfo[ nClr ][ 1 ] - 1 ) )

         Gradient( hDC, { nTop, nLeft, nSlice, nRight },;
                   aGradInfo[ nClr ][ 2 ], aGradInfo[ nClr ][ 3 ], .T. )

         nTop = nSlice + 1

         if nTop > nBottom
            exit
         endif
      next

   else


Please replace the above block of code with this block:
Code (fw): Select all Collapse
   if lVert
      nSize    := nBottom - nTop //+ 1

      for nClr := 1 to nClrs

         nSlice = If( nClr == nClrs, nBottom, ;
                     Min( nBottom, nTop + nSize * aGradInfo[ nClr ][ 1 ] - 1 ) )

         Gradient( hDC, { nTop, nLeft, nSlice - 1, nRight },;
                   aGradInfo[ nClr ][ 2 ], aGradInfo[ nClr ][ 3 ], .T. )

         nTop = nSlice //+ 1

         if nTop > nBottom
            exit
         endif
      next

   else


Please test with this change and let us know if this change solves the problem.
Regards



G. N. Rao.

Hyderabad, India
Posts: 694
Joined: Fri Oct 07, 2005 06:58 AM
Re: problema con xbrowse y Grid.
Posted: Sat Sep 03, 2022 08:28 AM

Perfect.
It works perfectly.

Thank you very much

Un saludo

Fernando González Diez

ALSIS Sistemas Informáticos
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: problema con xbrowse y Grid.
Posted: Sat Sep 03, 2022 08:43 AM
fgondi wrote:Perfect.
It works perfectly.

Thank you very much


Did you remove "oBrw:lFullPaint := .t." and test?
Thanks for testing.
Regards



G. N. Rao.

Hyderabad, India
Posts: 10733
Joined: Sun Nov 19, 2006 05:22 AM
Re: problema con xbrowse y Grid.
Posted: Sat Sep 03, 2022 08:45 AM
richard-service wrote:
Antonio Linares wrote:Fernando,

El Sr. Rao me comentó ayer que esto es una solución temporal y que se pone manos a la obra para solucionarlo correctamente

Démosle tiempo para poder hacerlo :-)

un abrazo


Ok. Waiting for it.


Please test and confirm.

I need all your help because I have poor eye vision.
I can not accurately decide by myself.
Regards



G. N. Rao.

Hyderabad, India
Posts: 694
Joined: Fri Oct 07, 2005 06:58 AM
Re: problema con xbrowse y Grid (SOLUCIONADO)
Posted: Sat Sep 03, 2022 10:01 AM

Yes, I removed "oBrw:lFullPaint := .t."

Un saludo

Fernando González Diez

ALSIS Sistemas Informáticos
Posts: 866
Joined: Tue Oct 16, 2007 08:57 AM
Re: problema con xbrowse y Grid.
Posted: Sun Sep 04, 2022 03:48 AM
nageswaragunupudi wrote:Can you both please help me by testing this fix?

In the program
fwh\source\function\imgtxtio.prg,
function GradientFill(...)

Please locate these lines of code:
Code (fw): Select all Collapse
   if lVert
      nSize    := nBottom - nTop + 1

      for nClr := 1 to nClrs

         nSlice = If( nClr == nClrs, nBottom, ;
                     Min( nBottom, nTop + nSize * aGradInfo[ nClr ][ 1 ] - 1 ) )

         Gradient( hDC, { nTop, nLeft, nSlice, nRight },;
                   aGradInfo[ nClr ][ 2 ], aGradInfo[ nClr ][ 3 ], .T. )

         nTop = nSlice + 1

         if nTop > nBottom
            exit
         endif
      next

   else


Please replace the above block of code with this block:
Code (fw): Select all Collapse
   if lVert
      nSize    := nBottom - nTop //+ 1

      for nClr := 1 to nClrs

         nSlice = If( nClr == nClrs, nBottom, ;
                     Min( nBottom, nTop + nSize * aGradInfo[ nClr ][ 1 ] - 1 ) )

         Gradient( hDC, { nTop, nLeft, nSlice - 1, nRight },;
                   aGradInfo[ nClr ][ 2 ], aGradInfo[ nClr ][ 3 ], .T. )

         nTop = nSlice //+ 1

         if nTop > nBottom
            exit
         endif
      next

   else


Please test with this change and let us know if this change solves the problem.


Dear Mr.Rao

not work.
Best Regards,



Richard



Harbour 3.2.0dev (r2503251254) => Borland C++ v7.7 32bit

MySQL v8.0

Harbour 3.2.0dev (r2503251254) => Borland C++ v7.7 64bit

Continue the discussion