From: Vincent Poirriez <Vincent.Poirriez@univ-valenciennes.fr>
To: caml-list@inria.fr
Cc: vincent.poirriez@univ-valenciennes.fr
Subject: [Caml-list] Camltk and Font_Size
Date: Thu, 20 Mar 2003 15:45:34 +0100 [thread overview]
Message-ID: <20030320154534.33e86727.Vincent.Poirriez@univ-valenciennes.fr > (raw)
Hello,
a simple question concerning the Camltk API.
What is the simplest way to specify the size of the font used in a widget.
I've found Font_Size but when I try to use it, it raises Invalid_argument("Font_Size")
I'll appreciate any indication.
Vincent
Below the program helloworld.ml modified from the examples_camltk directory of the distribution
open Camltk;; (* Make interface functions available *)
let top = opentk ();; (* Initialisation of the interface *)
(* top is now the toplevel widget *)
(* Widget initialisation *)
let b = Button.create top
[Text "foobar";
Command (function () ->
print_string "foobar";
print_newline();
flush stdout)];;
(* b exists but is not yet visible *)
let q = Button.create top
[Text "quit"; Font_Size 12;
Command closeTk];;
(* q exists but is not yet visible *)
pack [b; q][] ;; (* Make b visible *)
mainLoop() ;; (* User interaction*)
--
courriel: vincent.poirriez@univ-valenciennes.fr
tel: (33)[0]3 27 51 19 53
Université de Valenciennes et du Hainaut-Cambrésis - Le Mont Houy
F-59313 Valenciennes cedex 9 - FRANCE
http://www.univ-valenciennes.fr/LAMIH/ROI/poirriez
-------------------
To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr
Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
next reply other threads:[~2003-03-20 14:50 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-03-20 14:45 Vincent Poirriez [this message]
2003-03-20 16:08 ` Jun P. FURUSE
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='20030320154534.33e86727.Vincent.Poirriez@univ-valenciennes.fr ' \
--to=vincent.poirriez@univ-valenciennes.fr \
--cc=caml-list@inria.fr \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox