📄 options.tk
字号:
#!/usr/bin/wish -f# We set the global variable state equal to 1.# We create a check button and an options menu.# These are packed side by side.set state 1checkbutton .lan -text "Language" -command {changeState} -relief flat \ -variable state -onvalue 1 -offvalue 0set optMenu [tk_optionMenu .opt lang Tcl C Lisp C++]pack .lan .opt -side left# now make C As the default using lang variableset lang C++# We need a procedure to handle the application's event.proc changeState {} { global state if $state { .opt config -state normal } else { .opt config -state disabled }}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -