Bug in FolderEx ...

Re: Bug in FolderEx ...

Postby Rimantas » Wed Dec 14, 2011 6:55 pm

Daniel Garcia-Gil wrote:Hello

danielgarciagil@gmail.com
compress to .zip and rename file to .zop


Alreday sent ... :)
Rimantas U.
User avatar
Rimantas
 
Posts: 437
Joined: Fri Oct 07, 2005 12:56 pm
Location: Utena , Lithuania

Re: Bug in FolderEx ...

Postby Daniel Garcia-Gil » Wed Dec 14, 2011 7:01 pm

Rimantas

the lithuanian prompts is not showed :-(

send me the prg too

what text editor are you using?
User avatar
Daniel Garcia-Gil
 
Posts: 2365
Joined: Wed Nov 02, 2005 11:46 pm
Location: Isla de Margarita

Re: Bug in FolderEx ...

Postby Rimantas » Thu Dec 15, 2011 6:06 am

Daniel Garcia-Gil wrote:Rimantas

the lithuanian prompts is not showed :-(

send me the prg too

what text editor are you using?


Daniel , we forgoted that on windows nationals chars are working fine ... So source here is not related .

Regards !
Rimantas U.
User avatar
Rimantas
 
Posts: 437
Joined: Fri Oct 07, 2005 12:56 pm
Location: Utena , Lithuania

Re: Bug in FolderEx ...

Postby Antonio Linares » Thu Dec 15, 2011 10:17 am

Rimantas,

Are the same prompts are fine with a standard TFolder (SysTabControl32) ?

We use DrawText() to paint the promts. As those are in unicode I think that you could try to call DrawTextW() instead of DrawTextA(). By default (non unicode) DrawText() gets translated into DrawTextA().
regards, saludos

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

Re: Bug in FolderEx ...

Postby Rimantas » Thu Dec 15, 2011 10:26 am

Antonio.

Antonio Linares wrote:Are the same prompts are fine with a standard TFolder (SysTabControl32) ?


Standard TFolder works fine in all cases - dialogs & windows .

We use DrawText() to paint the promts. As those are in unicode I think that you could try to call DrawTextW() instead of DrawTextA(). By default (non unicode) DrawText() gets translated into DrawTextA().


Where I can to try that ? Can you direct to source ?

Thanks ! With best regards !
Rimantas U.
User avatar
Rimantas
 
Posts: 437
Joined: Fri Oct 07, 2005 12:56 pm
Location: Utena , Lithuania

Re: Bug in FolderEx ...

Postby Antonio Linares » Thu Dec 15, 2011 10:37 am

Rimantas,

Please try this example using some unicode text:

Code: Select all  Expand view
#include "FiveWin.ch"

function Main()

   local oDlg

   DEFINE DIALOG oDlg

   ACTIVATE DIALOG oDlg CENTERED ;
      ON PAINT DrawTextW( hDC, Unicode_Text, { 10, 10, 30, 100 } )

return nil

#pragma BEGINDUMP

#include <windows.h>
#include <hbapi.h>

HB_FUNC( DRAWTEXTW )
{
   RECT rct;
   
   rct.top    = hb_parvni( 3, 1 );
   rct.left   = hb_parvni( 3, 2 );
   rct.bottom = hb_parvni( 3, 3 );
   rct.right  = hb_parvni( 3, 4 );

   DrawTextW( ( HDC ) hb_parnl( 1 ), ( char * ) hb_parc( 2 ), hb_parclen( 2 ), &rct, DT_LEFT );
}

#pragma ENDDUMP  
regards, saludos

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

Re: Bug in FolderEx ...

Postby Rimantas » Thu Dec 15, 2011 4:27 pm

Antonio Linares wrote:Rimantas,
Please try this example using some unicode text:

Code: Select all  Expand view
#include "FiveWin.ch"
function Main()
   local oDlg
   DEFINE DIALOG oDlg
   ACTIVATE DIALOG oDlg CENTERED ;
      ON PAINT DrawTextW( hDC, Unicode_Text, { 10, 10, 30, 100 } )
return nil
#pragma BEGINDUMP
#include <windows.h>
#include <hbapi.h>

HB_FUNC( DRAWTEXTW )
#pragma ENDDUMP  


Maybe I something didn't understand ... I writed instead "Unicode_Text" own text . Here is sample :


http://imageshack.us/photo/my-images/440/band1r.jpg/

Then tried with DrawText() function :
http://imageshack.us/photo/my-images/13/band2wb.jpg/

And at last tried with simple SAY :

Code: Select all  Expand view

#include "FiveWin.ch"
function Main()
   local oDlg
   DEFINE DIALOG oDlg TITLE "Bandymėlis ... Ąčęėįšųūž "
   @ 10, 30 SAY "Linksmų Kalėdų ! Ąčęėįšųūž " PIXEL OF oDlg
   ACTIVATE DIALOG oDlg CENTERED
return nil
 


http://imageshack.us/photo/my-images/24/band3g.jpg/

It's related to FolderEx tab dialog ?
Rimantas U.
User avatar
Rimantas
 
Posts: 437
Joined: Fri Oct 07, 2005 12:56 pm
Location: Utena , Lithuania

Re: Bug in FolderEx ...

Postby Antonio Linares » Thu Dec 15, 2011 4:49 pm

If the example is properly shown with standard DrawText() then it means that you are not displaying unicode.

Class TFolderEx() is using standard DrawText()
regards, saludos

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

Re: Bug in FolderEx ...

Postby Rimantas » Thu Dec 15, 2011 6:27 pm

Antonio Linares wrote:If the example is properly shown with standard DrawText() then it means that you are not displaying unicode.
Class TFolderEx() is using standard DrawText()


With DrawText all is OK ... Can you get some ideas , why it's not working with mine samples with FolderEx on Dialogs ? I like FolderEx , it works fine . Exspecially like the feature hide/unhide folder tabs . I'm working in enterprise "Utenos trikotazas" and we have subsidiary enterprise in Ukrainian city Mukachevo , "Mryia" . We don't know ukrainian language , but from the common past ( in the USSR ) we know russian language . And I'm preparing program in 3 languages - lithuanian , russian and all invoices and packing-slips in english also . So the cyrillics it's needfull for me . With lithuanian I can write , as we are naming "tongue-tieded" ... :) , without nat.chars "ąčęėįšųūž" . At first I saw problem with cyrrilics notes ...

Any ideas ?

With best regards !
Rimantas U.
User avatar
Rimantas
 
Posts: 437
Joined: Fri Oct 07, 2005 12:56 pm
Location: Utena , Lithuania

Re: Bug in FolderEx ...

Postby Antonio Linares » Thu Dec 15, 2011 6:35 pm

Rimantas,

Does it look wrong in TFolderEx ? Or you simply get nothing ?
regards, saludos

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

Re: Bug in FolderEx ...

Postby Rimantas » Thu Dec 15, 2011 7:27 pm

Antonio Linares wrote:Rimantas,
Does it look wrong in TFolderEx ? Or you simply get nothing ?


Antonio ,
It looks wrong in TFolderEx and only when FolDerEx is placed on Dialog . When placing FolderEx on windows then is working fine .
Code: Select all  Expand view

#include "FiveWin.ch"
function main()
   local oWnd, oFld
   DEFINE DIALOG oWnd TITLE "TFolderex - DIALOG -"
   @ 3, 3 FOLDEREX oFld PIXEL ADJUST PROMPT   "&OS", "&Žaidimai", "&Movies", "&Ūsai"

   @ 1,3 SAY "UNDER CONSTRUCTION" OF oFld:aDialogs[ 1 ] TRANSPARENT
   @ 40,50 SAY "Linksmų Kalėdų! Lithuanian chars - ąčęėįšųūž - " OF oFld:aDialogs[ 1 ] PIXEL TRANSPARENT

   ACTIVATE DIALOG oWnd
RETURN NIL
 


Compile this sample in fwh\samples directory with buildg.bat . I'm not seeing lithuanian chars ... Daniel did sample - he is seeing ... Can't understand where is problem ... After discusion with Daniel I was thinking that maybe source code - did all variants with notepad ( Save As , Encoding types ) . No good results ... :(
Rimantas U.
User avatar
Rimantas
 
Posts: 437
Joined: Fri Oct 07, 2005 12:56 pm
Location: Utena , Lithuania

Re: Bug in FolderEx ...

Postby Antonio Linares » Thu Dec 15, 2011 7:50 pm

Rimantas,

Here it looks fine:

Image

We need to find a way to reproduce what you get there...
regards, saludos

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

Re: Bug in FolderEx ...

Postby Rimantas » Thu Dec 15, 2011 8:28 pm

Antonio Linares wrote:Rimantas,

Here it looks fine:
We need to find a way to reproduce what you get there...


It make me crazy ...
Antonio , can you say how to did sample with DrawTextW() on folder tab ? Can't to make this ... Maybe here is the problem ?
Rimantas U.
User avatar
Rimantas
 
Posts: 437
Joined: Fri Oct 07, 2005 12:56 pm
Location: Utena , Lithuania

Re: Bug in FolderEx ...

Postby Rimantas » Fri Dec 16, 2011 5:49 am

Antonio Linares wrote:Rimantas,
Here it looks fine:
We need to find a way to reproduce what you get there...


Antonio - request ... Can you change line with SAY and then try ?

Code: Select all  Expand view

 @ 40,50 SAY "Linksmų Kalėdų! Lithuanian chars - ąčęėįšųūž - " OF oFld:aDialogs[ 1 ] PIXEL TRANSPARENT
 


Regards !
Rimantas U.
User avatar
Rimantas
 
Posts: 437
Joined: Fri Oct 07, 2005 12:56 pm
Location: Utena , Lithuania

Re: Bug in FolderEx ...

Postby Rimantas » Fri Dec 16, 2011 6:33 pm

Hi to all ! :)

It seems that I solved this problem with FolderEx ... If you remember , some times ago I wrote a message , that can't see nationals chars in VistaMenu . Then I directed font "Times New Roman Baltic" and then national chars appears . So I did the same with folderEx on dialogs :

Code: Select all  Expand view

#include "FiveWin.ch"

function main()
   local oWnd
   local oFld
   local oFont
   
   DEFINE FONT oFont  NAME "Times New Roman Baltic"

   DEFINE DIALOG oWnd TITLE "TFolderex - DIALOG -" FONT oFont

   @ 3, 3 FOLDEREX oFld PIXEL ADJUST PROMPT   "Žaidimai", "Lietuviškai", "Ąčęėįšųūž"

   @ 1,3 SAY "UNDER CONSTRUCTION" OF oFld:aDialogs[ 1 ] TRANSPARENT
   @ 40,50 SAY "Linksmų Kalėdų !" OF oFld:aDialogs[ 1 ] PIXEL TRANSPARENT

   ACTIVATE DIALOG oWnd

   oFont:End()
RETURN NIL
 


Now I can see national chars in prompts and folder tab ... But ... The choice of fonts with "Baltic" is minimal ... And second question - why it's not working with font of system ? And in some places - vistaMenu , FolderEx on dialogs ? If you remember - nationals chars works fine on standard folders in both cases , windows and dialogs ...

With best regards !
Rimantas U.
User avatar
Rimantas
 
Posts: 437
Joined: Fri Oct 07, 2005 12:56 pm
Location: Utena , Lithuania

PreviousNext

Return to FiveWin for Harbour/xHarbour

Who is online

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