File: hello.tcl

package info (click to toggle)
gettext 0.14.4-2
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 37,764 kB
  • ctags: 9,842
  • sloc: ansic: 87,836; sh: 41,602; makefile: 7,790; perl: 4,154; lisp: 2,899; cs: 548; yacc: 527; java: 506; sed: 357; objc: 337; cpp: 254; awk: 81; tcl: 63; pascal: 12; php: 8
file content (20 lines) | stat: -rw-r--r-- 517 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#!@WISH@
# Example for use of GNU gettext.
# Copyright (C) 2003 Free Software Foundation, Inc.
# This file is in the public domain.
#
# Source code of the Tcl/Tk program.

package require msgcat
::msgcat::mcload [file join "@pkgdatadir@" "msgs"]
proc _ {s} {return [::msgcat::mc $s]}

frame .my
button .my.button \
  -text [_ "Hello, world!"] \
  -command exit
label .my.label \
  -text [format [_ "This program is running as process number %d."] [pid]]
pack .my.button -side top
pack .my.label -side bottom
pack .my