Hallo,
how do I can set the Font of a RADIO controll in a Folder?
RADIO Controll from Source (@ x,y RADIO ...)
Best regards
Norbert
EnricoMaria wrote:Can you show me a reduced and self-contained sample of the problem?
EMG
function Main()
local nValue := 3, oRad
SET _3DLOOK ON
SET HELPFILE TO "Test.hlp"
DEFINE WINDOW oWnd ;
TITLE "Testing a Radio Buttons Menu" COLOR "N/W"
@ 1, 1 BUTTON "&Test" SIZE 70, 20 ;
ACTION ( MsgInfo( nValue ), oRad:aItems[ 2 ]:SetText( "&Changed!" ) )
@ 3, 2 RADIO oRad VAR nValue ;
ITEMS "&One", "&Two", "T&hree" _3D SIZE 150, 25 ;
HELPID 100, 101, 102 ;
ON CHANGE MsgBeep()
// adding an extra radio item at a different location
@ 5, 25 RADIOITEM "Fo&ur" RADIOMENU oRad OF oWnd SIZE 150, 25
ACTIVATE WINDOW oWnd
return nil
#include "FiveWin.ch"
function Main()
local nValue := 3, oRad, oFont, n
SET _3DLOOK ON
SET HELPFILE TO "Test.hlp"
DEFINE WINDOW oWnd ;
TITLE "Testing a Radio Buttons Menu" COLOR "N/W"
@ 1, 1 BUTTON "&Test" SIZE 70, 20 ;
ACTION ( MsgInfo( nValue ), oRad:aItems[ 2 ]:SetText( "&Changed!" ) )
@ 3, 2 RADIO oRad VAR nValue ;
ITEMS "&One", "&Two", "T&hree" _3D SIZE 150, 25 ;
HELPID 100, 101, 102 ;
ON CHANGE MsgBeep()
// adding an extra radio item at a different location
@ 5, 25 RADIOITEM "Fo&ur" RADIOMENU oRad OF oWnd SIZE 150, 25
DEFINE FONT oFont NAME "Verdana" SIZE 0, -10
for n = 1 to Len( oRad:aItems )
oRad:aItems[ n ]:SetFont( oFont )
next
ACTIVATE WINDOW oWnd
return nil
#include "Fivewin.ch"
function Main()
local oWnd
local nValue := 3, oRad
local oFnt
SET _3DLOOK ON
SET HELPFILE TO "Test.hlp"
DEFINE FONT oFnt NAME "Arial" SIZE 0, -8
DEFINE WINDOW oWnd ;
TITLE "Testing a Radio Buttons Menu" COLOR "N/W"
@ 1, 1 BUTTON "&Test" SIZE 70, 20 ;
ACTION ( MsgInfo( nValue ), oRad:aItems[ 2 ]:SetText( "&Changed!" ) )
@ 1, 20 BUTTON "&Change font" SIZE 70, 20 ;
ACTION ( oRad:aItems[ 2 ]:SetFont( oFnt ),;
INVALIDATERECT( oRad:aItems[ 2 ]:hWnd ) )
@ 3, 2 RADIO oRad VAR nValue ;
ITEMS "&One", "&Two", "T&hree" _3D SIZE 150, 25 ;
HELPID 100, 101, 102 ;
ON CHANGE MsgBeep()
// adding an extra radio item at a different location
@ 5, 25 RADIOITEM "Fo&ur" RADIOMENU oRad OF oWnd SIZE 150, 25
ACTIVATE WINDOW oWnd
RELEASE FONT oFnt
return nil
EnricoMaria wrote:Here it is:
- Code: Select all Expand view
#include "Fivewin.ch"
function Main()
local oWnd
local nValue := 3, oRad
local oFnt
SET _3DLOOK ON
SET HELPFILE TO "Test.hlp"
DEFINE FONT oFnt NAME "Arial" SIZE 0, -8
DEFINE WINDOW oWnd ;
TITLE "Testing a Radio Buttons Menu" COLOR "N/W"
@ 1, 1 BUTTON "&Test" SIZE 70, 20 ;
ACTION ( MsgInfo( nValue ), oRad:aItems[ 2 ]:SetText( "&Changed!" ) )
@ 1, 20 BUTTON "&Change font" SIZE 70, 20 ;
ACTION ( oRad:aItems[ 2 ]:SetFont( oFnt ),;
INVALIDATERECT( oRad:aItems[ 2 ]:hWnd ) )
@ 3, 2 RADIO oRad VAR nValue ;
ITEMS "&One", "&Two", "T&hree" _3D SIZE 150, 25 ;
HELPID 100, 101, 102 ;
ON CHANGE MsgBeep()
// adding an extra radio item at a different location
@ 5, 25 RADIOITEM "Fo&ur" RADIOMENU oRad OF oWnd SIZE 150, 25
ACTIVATE WINDOW oWnd
RELEASE FONT oFnt
return nil
EMG
Return to FiveWin for Harbour/xHarbour
Users browsing this forum: No registered users and 87 guests