try this test pls.
- Code: Select all Expand view RUN
#include "fivewin.ch"
Function Main()
Local oDlg, oFld
Local oLbx,oLbx2,oLbx3,oLbx4,oLbx5,oLbx6
Local oFont1d
DEFINE FONT oFont1d NAME "Arial" SIZE 0,-36 NESCAPEMENT 90*10
DEFINE DIALOG oDlg TITLE "test" ;
FROM 5, 5 TO 30, 55
@ 0.2, 1 FOLDER oFld PROMPT;
"1111111111",;
"222222222",;
"33333" ,;
"4444444" ,;
"55555555" ,;
"66666666666" ,;
"777777777" ,;
"88888888888888" ,;
"999999999999",;
"1010101010" ,;
"111111111111" ,;
"121212121212" ,;
"Autori" ;
OF oDlg SIZE 185, 165
ACTIVATE DIALOG oDlg CENTERED ;
On Paint SayRotated(oFld:aDialogs[13],1,4,"scritta verticale",oFont1D,,,.t.)
return nil
Function SayRotated(oWnd,Y,X,cPrompt,oFont,nClrText,nClrPane,l3D)
Local hDC:=oWnd:hDC
DEFAULT nClrText:=CLR_BLUE, l3D:=.T.
IF l3D
DrawRotated(hdc, cPrompt, Y + 1, X + 1, CLR_BLACK,nClrPane,oFont)
DrawRotated(hdc, cPrompt, Y - 1, X - 1, nClrText,nClrPane,oFont)
ENDIF
DrawRotated(hdc, cPrompt, Y , X , nClrText,nClrPane,oFont)
return
Static Function DrawRotated(hDC,cPrompt,Y,X,nClrText,nClrPane,oFont)
Local hOldFont, nOldMode, nOldClrText, nOldClrPane
nOldClrText:=SetTextColor(hDC,nClrText)
if nClrPane<>nil
nOldClrPane:=SetBkColor(hDC,nClrPane)
else
nOldBkMode:=SetBkMode(hDC,1)
endif
hOldFont:=SelectObject(hDC,oFont:hFont)
TextOut(hDC,Y,X,cPrompt,Len(cPrompt))
SelectObject(hDC,hOldFont)
if nClrPane<>nil
SetBkColor(hDC,nOldClrPane)
else
SetBkMode(hDC,nOldBkMode)
endif
SetTextColor(hDC,nOldClrText)
retur