| Server IP : 77.68.64.21 / Your IP : 216.73.217.105 Web Server : Apache System : Linux hp3-wp-1011378.hostingp3.local 3.10.0-1160.144.1.el7.tuxcare.els9.x86_64 #1 SMP Fri Jul 10 17:06:31 UTC 2026 x86_64 User : csh2668128 ( 2112425) PHP Version : 8.1.34 Disable Function : shell_exec,exec,system,popen,set_time_limit MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /usr/share/tcl8.5/bwidget1.9.0/ |
Upload File : |
# ------------------------------------------------------------------------------
# labelentry.tcl
# This file is part of Unifix BWidget Toolkit
# $Id: labelentry.tcl,v 1.6 2003/10/20 21:23:52 damonc Exp $
# ------------------------------------------------------------------------------
# Index of commands:
# - LabelEntry::create
# - LabelEntry::configure
# - LabelEntry::cget
# - LabelEntry::bind
# ------------------------------------------------------------------------------
namespace eval LabelEntry {
Widget::define LabelEntry labelentry Entry LabelFrame
Widget::bwinclude LabelEntry LabelFrame .labf \
remove {-relief -borderwidth -focus} \
rename {-text -label} \
prefix {label -justify -width -anchor -height -font -textvariable}
Widget::bwinclude LabelEntry Entry .e \
remove {-fg -bg} \
rename {-foreground -entryfg -background -entrybg}
Widget::addmap LabelEntry "" :cmd {-background {}}
Widget::syncoptions LabelEntry Entry .e {-text {}}
Widget::syncoptions LabelEntry LabelFrame .labf {-label -text -underline {}}
::bind BwLabelEntry <FocusIn> [list focus %W.labf]
::bind BwLabelEntry <Destroy> [list LabelEntry::_destroy %W]
}
# ------------------------------------------------------------------------------
# Command LabelEntry::create
# ------------------------------------------------------------------------------
proc LabelEntry::create { path args } {
array set maps [list LabelEntry {} :cmd {} .labf {} .e {}]
array set maps [Widget::parseArgs LabelEntry $args]
eval [list frame $path] $maps(:cmd) -class LabelEntry \
-relief flat -bd 0 -highlightthickness 0 -takefocus 0
Widget::initFromODB LabelEntry $path $maps(LabelEntry)
set labf [eval [list LabelFrame::create $path.labf] $maps(.labf) \
[list -relief flat -borderwidth 0 -focus $path.e]]
set subf [LabelFrame::getframe $labf]
set entry [eval [list Entry::create $path.e] $maps(.e)]
pack $entry -in $subf -fill both -expand yes
pack $labf -fill both -expand yes
bindtags $path [list $path BwLabelEntry [winfo toplevel $path] all]
return [Widget::create LabelEntry $path]
}
# ------------------------------------------------------------------------------
# Command LabelEntry::configure
# ------------------------------------------------------------------------------
proc LabelEntry::configure { path args } {
return [Widget::configure $path $args]
}
# ------------------------------------------------------------------------------
# Command LabelEntry::cget
# ------------------------------------------------------------------------------
proc LabelEntry::cget { path option } {
return [Widget::cget $path $option]
}
# ------------------------------------------------------------------------------
# Command LabelEntry::bind
# ------------------------------------------------------------------------------
proc LabelEntry::bind { path args } {
return [eval [list ::bind $path.e] $args]
}
#------------------------------------------------------------------------------
# Command LabelEntry::_path_command
#------------------------------------------------------------------------------
proc LabelEntry::_path_command { path cmd larg } {
if { [string equal $cmd "configure"] ||
[string equal $cmd "cget"] ||
[string equal $cmd "bind"] } {
return [eval [list LabelEntry::$cmd $path] $larg]
} else {
return [eval [list $path.e:cmd $cmd] $larg]
}
}
proc LabelEntry::_destroy { path } {
Widget::destroy $path
}