Cambio FONT su prompts di un FOLDER

Moderator: Enrico Maria Giordano

Cambio FONT su prompts di un FOLDER

Postby max » Mon Sep 01, 2008 5:29 pm

Non riesco a cambiare il font dei prompt di una folder creata da sorgente.
Ho scritto così, ma il font rimane sempre quello di default:

local oDLG, oFLD,fntArial
DEFINE FONT fntArial NAME "Arial" SIZE 0, -20
DEFINE DIALOG odlg FROM 1,1 to 45,125 TITLE "Prova dialog"
@ 1,1 FOLDER oFLD PROMPTS "PRIMA","SECONDA" SIZE 460,300 PIXEL FONT fntArial
ACTIVATE DIALOG oDlg CENTERED

Solo se lo associo alla dialog oDLG allora cambia, ma a quel punto mi cambia tutta la dialog e non solo i prompt del folder come vorrei.
Ho anche provato con il
SET FONT OF oFLD:aprompts[1] TO fntArial ,

ma nulla da fare (errore in runtime).

Dove sbaglio?
User avatar
max
 
Posts: 128
Joined: Fri Jun 30, 2006 2:14 pm
Location: Ancona - Italy

Postby Antonio Linares » Mon Sep 01, 2008 7:24 pm

Max,

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

function Main()   

   local oDLG, oFLD, fntArial

   DEFINE FONT fntArial NAME "Arial" SIZE 0, -20

   DEFINE DIALOG odlg FROM 1,1 to 45,125 TITLE "Prova dialog"

   @ 1, 1 FOLDER oFLD PROMPTS "PRIMA","SECONDA" SIZE 460,300 PIXEL

   ACTIVATE DIALOG oDlg CENTERED ;
      ON INIT oFld:SetFont( fntArial )

return nil
regards, saludos

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

Postby max » Tue Sep 02, 2008 10:18 am

ok, grazie!
But where i can find a documentation updated with all methods that i can use for each object?
Now during my work i search in examples \fwh\samples\ and in documentation file *.chm in \fwh\manual, but (for example) i have not find this methods you wrote ( ofld:setfont(), that works fine ) in this documentation...

Or is better asking in the forum?
Thank you.

MT

FWH 8.04 + XHARBOUR 1.1.0
User avatar
max
 
Posts: 128
Joined: Fri Jun 30, 2006 2:14 pm
Location: Ancona - Italy

Postby Antonio Linares » Tue Sep 02, 2008 11:14 am

Max,

You are welcome to ask in these forums for any help that you may need.

The Method SetFont() belongs to Class TWindow. From TWindow, Class TControl is inherited, and from TControl, Class TFolder is inherited. So Class TFolder has inherited Method SetFont() too.

Its a good practice to review the FiveWin source code to get a good understanding about its object oriented design.
regards, saludos

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


Return to All products support

Who is online

Users browsing this forum: No registered users and 10 guests