mirror of
https://github.com/NGSolve/netgen.git
synced 2024-12-24 21:10:33 +05:00
small tix fix
This commit is contained in:
parent
112b00ed29
commit
2a380690d1
@ -54,7 +54,7 @@ proc show_menu_help { entry } {
|
||||
}
|
||||
|
||||
|
||||
tixBalloon .balloon -statusbar .helpline
|
||||
#tixBalloon .balloon -statusbar .helpline
|
||||
|
||||
proc set_control_help { control helpmsg } {
|
||||
bind $control <Enter> "show_control_help {$helpmsg}"
|
||||
|
248
ng/ngvisual.tcl
248
ng/ngvisual.tcl
@ -1654,177 +1654,177 @@ proc visual_dialog { } {
|
||||
|
||||
|
||||
|
||||
proc reset_visual_dialog { } {
|
||||
# proc reset_visual_dialog { } {
|
||||
|
||||
set w .visoptions_dlg
|
||||
# set w .visoptions_dlg
|
||||
|
||||
if {[winfo exists .visoptions_dlg] == 1} {
|
||||
# if {[winfo exists .visoptions_dlg] == 1} {
|
||||
|
||||
|
||||
destroy $w.scalfun $w.vecfun $w.evaluate $w.multidimcomp
|
||||
destroy $w.imaginary $w.logscale $w.texframe.usetexture $w.texframe.lintexture
|
||||
destroy $w.texframe
|
||||
destroy $w.invcolor $w.redrawperiodic
|
||||
destroy $w.bu -pady 5
|
||||
destroy $w.bu.showsol $w.bu.clipping $w.bu.fieldlines $w.bu.lineplot $w.bu.done -side left -expand yes
|
||||
# destroy $w.scalfun $w.vecfun $w.evaluate $w.multidimcomp
|
||||
# destroy $w.imaginary $w.logscale $w.texframe.usetexture $w.texframe.lintexture
|
||||
# destroy $w.texframe
|
||||
# destroy $w.invcolor $w.redrawperiodic
|
||||
# destroy $w.bu -pady 5
|
||||
# destroy $w.bu.showsol $w.bu.clipping $w.bu.fieldlines $w.bu.lineplot $w.bu.done -side left -expand yes
|
||||
|
||||
|
||||
checkbutton $w.imaginary -text "Imaginary Part" \
|
||||
-variable visoptions.imaginary \
|
||||
-command { Ng_Vis_Set parameters; redraw }
|
||||
# checkbutton $w.imaginary -text "Imaginary Part" \
|
||||
# -variable visoptions.imaginary \
|
||||
# -command { Ng_Vis_Set parameters; redraw }
|
||||
|
||||
frame $w.texframe
|
||||
# frame $w.texframe
|
||||
|
||||
checkbutton $w.texframe.usetexture -text "Use Textures (" \
|
||||
-variable visoptions.usetexture \
|
||||
-command { Ng_Vis_Set parameters; redraw }
|
||||
# checkbutton $w.texframe.usetexture -text "Use Textures (" \
|
||||
# -variable visoptions.usetexture \
|
||||
# -command { Ng_Vis_Set parameters; redraw }
|
||||
|
||||
checkbutton $w.texframe.lintexture -text "Linear )" \
|
||||
-variable visoptions.lineartexture \
|
||||
-command { Ng_Vis_Set parameters; redraw }
|
||||
# checkbutton $w.texframe.lintexture -text "Linear )" \
|
||||
# -variable visoptions.lineartexture \
|
||||
# -command { Ng_Vis_Set parameters; redraw }
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
checkbutton $w.invcolor -text "Inverse Color" \
|
||||
-variable visoptions.invcolor \
|
||||
-command { Ng_Vis_Set parameters; redraw }
|
||||
# checkbutton $w.invcolor -text "Inverse Color" \
|
||||
# -variable visoptions.invcolor \
|
||||
# -command { Ng_Vis_Set parameters; redraw }
|
||||
|
||||
checkbutton $w.logscale -text "Log Scale" \
|
||||
-variable visoptions.logscale \
|
||||
-command { Ng_Vis_Set parameters; redraw }
|
||||
# checkbutton $w.logscale -text "Log Scale" \
|
||||
# -variable visoptions.logscale \
|
||||
# -command { Ng_Vis_Set parameters; redraw }
|
||||
|
||||
|
||||
|
||||
checkbutton $w.redrawperiodic -text "Animate periodic" \
|
||||
-variable visoptions.redrawperiodic \
|
||||
-command {
|
||||
redrawperiodic
|
||||
Ng_Vis_Set parameters;
|
||||
redraw
|
||||
}
|
||||
# checkbutton $w.redrawperiodic -text "Animate periodic" \
|
||||
# -variable visoptions.redrawperiodic \
|
||||
# -command {
|
||||
# redrawperiodic
|
||||
# Ng_Vis_Set parameters;
|
||||
# redraw
|
||||
# }
|
||||
|
||||
|
||||
tixOptionMenu $w.scalfun -label "Scalar Function: " \
|
||||
-options {
|
||||
label.width 18
|
||||
label.anchor e
|
||||
menubutton.width 12
|
||||
}
|
||||
# tixOptionMenu $w.scalfun -label "Scalar Function: " \
|
||||
# -options {
|
||||
# label.width 18
|
||||
# label.anchor e
|
||||
# menubutton.width 12
|
||||
# }
|
||||
|
||||
tixOptionMenu $w.vecfun -label "Vector Function: " \
|
||||
-options {
|
||||
label.width 18
|
||||
label.anchor e
|
||||
menubutton.width 12
|
||||
}
|
||||
# tixOptionMenu $w.vecfun -label "Vector Function: " \
|
||||
# -options {
|
||||
# label.width 18
|
||||
# label.anchor e
|
||||
# menubutton.width 12
|
||||
# }
|
||||
|
||||
|
||||
|
||||
$w.scalfun add command none -label None
|
||||
for { set i 1 } { $i <= [Ng_Vis_Field getnfieldnames] } { incr i } {
|
||||
set fname [Ng_Vis_Field getfieldname $i]
|
||||
set fcomp [Ng_Vis_Field getfieldcomponents $i]
|
||||
if { $fcomp == 1 } {
|
||||
$w.scalfun add command $fname.1 -label $fname
|
||||
} {
|
||||
for { set j 1 } { $j <= $fcomp } { incr j } {
|
||||
$w.scalfun add command $fname.$j -label "$fname ($j)"
|
||||
}
|
||||
$w.scalfun add command $fname.0 -label "func ($fname)"
|
||||
}
|
||||
}
|
||||
# $w.scalfun add command none -label None
|
||||
# for { set i 1 } { $i <= [Ng_Vis_Field getnfieldnames] } { incr i } {
|
||||
# set fname [Ng_Vis_Field getfieldname $i]
|
||||
# set fcomp [Ng_Vis_Field getfieldcomponents $i]
|
||||
# if { $fcomp == 1 } {
|
||||
# $w.scalfun add command $fname.1 -label $fname
|
||||
# } {
|
||||
# for { set j 1 } { $j <= $fcomp } { incr j } {
|
||||
# $w.scalfun add command $fname.$j -label "$fname ($j)"
|
||||
# }
|
||||
# $w.scalfun add command $fname.0 -label "func ($fname)"
|
||||
# }
|
||||
# }
|
||||
|
||||
$w.vecfun add command none -label None
|
||||
for { set i 1 } { $i <= [Ng_Vis_Field getnfieldnames] } { incr i } {
|
||||
set fname [Ng_Vis_Field getfieldname $i]
|
||||
set fcomp [Ng_Vis_Field getfieldcomponents $i]
|
||||
set iscomplex [Ng_Vis_Field iscomplex $i]
|
||||
set sdim [Ng_Vis_Field getdimension]
|
||||
if { $iscomplex == 1 } { set fcomp [expr $fcomp / 2] }
|
||||
if { ($fcomp == $sdim) || ($fcomp == 3) } {
|
||||
$w.vecfun add command $fname -label $fname
|
||||
}
|
||||
}
|
||||
# $w.vecfun add command none -label None
|
||||
# for { set i 1 } { $i <= [Ng_Vis_Field getnfieldnames] } { incr i } {
|
||||
# set fname [Ng_Vis_Field getfieldname $i]
|
||||
# set fcomp [Ng_Vis_Field getfieldcomponents $i]
|
||||
# set iscomplex [Ng_Vis_Field iscomplex $i]
|
||||
# set sdim [Ng_Vis_Field getdimension]
|
||||
# if { $iscomplex == 1 } { set fcomp [expr $fcomp / 2] }
|
||||
# if { ($fcomp == $sdim) || ($fcomp == 3) } {
|
||||
# $w.vecfun add command $fname -label $fname
|
||||
# }
|
||||
# }
|
||||
|
||||
|
||||
|
||||
$w.scalfun configure -variable visoptions.scalfunction
|
||||
$w.scalfun configure -command { Ng_Vis_Set parameters; redraw }
|
||||
$w.vecfun configure -variable visoptions.vecfunction
|
||||
$w.vecfun configure -command { Ng_Vis_Set parameters; redraw }
|
||||
# $w.scalfun configure -variable visoptions.scalfunction
|
||||
# $w.scalfun configure -command { Ng_Vis_Set parameters; redraw }
|
||||
# $w.vecfun configure -variable visoptions.vecfunction
|
||||
# $w.vecfun configure -command { Ng_Vis_Set parameters; redraw }
|
||||
|
||||
|
||||
# puts "sclfunction = ${visoptions.scalfunction}"
|
||||
# # puts "sclfunction = ${visoptions.scalfunction}"
|
||||
|
||||
|
||||
tixOptionMenu $w.evaluate -label "Evaluate: " \
|
||||
-options {
|
||||
label.width 18
|
||||
label.anchor e
|
||||
menubutton.width 12
|
||||
}
|
||||
$w.evaluate add command abs -label "|.|"
|
||||
$w.evaluate add command abstens -label "|tensor|"
|
||||
$w.evaluate add command mises -label "Mises"
|
||||
$w.evaluate add command main -label "Main"
|
||||
$w.evaluate configure -variable visoptions.evaluate
|
||||
$w.evaluate configure -command {
|
||||
Ng_Vis_Set parameters;
|
||||
redraw
|
||||
}
|
||||
# tixOptionMenu $w.evaluate -label "Evaluate: " \
|
||||
# -options {
|
||||
# label.width 18
|
||||
# label.anchor e
|
||||
# menubutton.width 12
|
||||
# }
|
||||
# $w.evaluate add command abs -label "|.|"
|
||||
# $w.evaluate add command abstens -label "|tensor|"
|
||||
# $w.evaluate add command mises -label "Mises"
|
||||
# $w.evaluate add command main -label "Main"
|
||||
# $w.evaluate configure -variable visoptions.evaluate
|
||||
# $w.evaluate configure -command {
|
||||
# Ng_Vis_Set parameters;
|
||||
# redraw
|
||||
# }
|
||||
|
||||
pack $w.scalfun $w.vecfun $w.evaluate
|
||||
# pack $w.scalfun $w.vecfun $w.evaluate
|
||||
|
||||
tixControl $w.multidimcomp -label "multidim-component: " -integer true \
|
||||
-variable visoptions.multidimcomponent -min 0 \
|
||||
-command { Ng_Vis_Set parameters; redraw } \
|
||||
-options {
|
||||
entry.width 6
|
||||
label.width 18
|
||||
label.anchor e
|
||||
}
|
||||
# tixControl $w.multidimcomp -label "multidim-component: " -integer true \
|
||||
# -variable visoptions.multidimcomponent -min 0 \
|
||||
# -command { Ng_Vis_Set parameters; redraw } \
|
||||
# -options {
|
||||
# entry.width 6
|
||||
# label.width 18
|
||||
# label.anchor e
|
||||
# }
|
||||
|
||||
|
||||
pack $w.multidimcomp
|
||||
# pack $w.multidimcomp
|
||||
|
||||
pack $w.imaginary $w.logscale $w.texframe $w.invcolor $w.redrawperiodic
|
||||
pack $w.texframe.usetexture $w.texframe.lintexture -side left -expand yes
|
||||
# pack $w.imaginary $w.logscale $w.texframe $w.invcolor $w.redrawperiodic
|
||||
# pack $w.texframe.usetexture $w.texframe.lintexture -side left -expand yes
|
||||
|
||||
|
||||
frame $w.bu
|
||||
pack $w.bu -pady 5
|
||||
# frame $w.bu
|
||||
# pack $w.bu -pady 5
|
||||
|
||||
button $w.bu.showsol -text "Show Solution" -command {
|
||||
set selectvisual solution
|
||||
Ng_SetVisParameters
|
||||
redraw
|
||||
}
|
||||
button $w.bu.clipping -text "Clipping" -command {
|
||||
clippingdialog;
|
||||
}
|
||||
button $w.bu.fieldlines -text "Fieldlines" -command {
|
||||
fieldlinesdialog;
|
||||
}
|
||||
# button $w.bu.showsol -text "Show Solution" -command {
|
||||
# set selectvisual solution
|
||||
# Ng_SetVisParameters
|
||||
# redraw
|
||||
# }
|
||||
# button $w.bu.clipping -text "Clipping" -command {
|
||||
# clippingdialog;
|
||||
# }
|
||||
# button $w.bu.fieldlines -text "Fieldlines" -command {
|
||||
# fieldlinesdialog;
|
||||
# }
|
||||
|
||||
button $w.bu.lineplot -text "2D Lineplot" -command {
|
||||
lineplotdialog;
|
||||
}
|
||||
# button $w.bu.lineplot -text "2D Lineplot" -command {
|
||||
# lineplotdialog;
|
||||
# }
|
||||
|
||||
button $w.bu.done -text "Close" -command {
|
||||
destroy .visoptions_dlg
|
||||
}
|
||||
# button $w.bu.done -text "Close" -command {
|
||||
# destroy .visoptions_dlg
|
||||
# }
|
||||
|
||||
pack $w.bu.showsol $w.bu.clipping $w.bu.fieldlines $w.bu.lineplot $w.bu.done -side left -expand yes
|
||||
# pack $w.bu.showsol $w.bu.clipping $w.bu.fieldlines $w.bu.lineplot $w.bu.done -side left -expand yes
|
||||
|
||||
wm withdraw $w
|
||||
wm deiconify $w
|
||||
# wm withdraw $w
|
||||
# wm deiconify $w
|
||||
|
||||
|
||||
}
|
||||
# }
|
||||
|
||||
}
|
||||
# }
|
||||
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user