Changeset 1483


Ignore:
Timestamp:
Jun 2, 2009, 8:43:00 AM (15 years ago)
Author:
gah
Message:

fix newlines when sending data to pymolproxy

Location:
trunk/gui/scripts
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/gui/scripts/gauge.tcl

    r1342 r1483  
    234234        switch -- $itk_option(-type) {
    235235            integer {
    236                 if {[string length $nv] <= 0
    237                       || ![string is integer $nv] } {
    238                     error "Should be an integer value"
     236                if { [scan $nv "%g" value] != 1 || int($nv) != $value } {
     237                    error "bad value \"$nv\": should be an integer value"
    239238                }
    240239            }
     
    243242                      || ![string is double $nv]
    244243                      || [regexp -nocase {^(inf|nan)$} $nv]} {
    245                     error "Should be a real number"
     244                    error "bad value \"$nv\": should be a real number"
    246245                }
    247246            }
  • trunk/gui/scripts/molvisviewer.tcl

    r1438 r1483  
    7070    public method ResetView {}
    7171
    72     protected method SendCmd {args}
     72    protected method SendCmd { string }
    7373    protected method Update { args }
    7474    protected method Rebuild { }
     
    598598}
    599599
    600 itcl::body Rappture::MolvisViewer::SendCmd { args } {
    601     debug "SendCmd $args"
     600itcl::body Rappture::MolvisViewer::SendCmd { cmd } {
     601    debug "in SendCmd ($cmd)\n"
    602602
    603603    if { $_buffering } {
     
    611611            set _rocker(server) $_rocker(client)
    612612        }
    613         append _outbuf "$args\n"
     613        append _outbuf "$cmd\n"
    614614    } else {
    615615        if { $_state(server) != $_state(client) } {
     
    623623            }
    624624        }
    625         eval SendBytes "$args\n"
     625        SendBytes "$cmd\n"
    626626    }
    627627}
     
    14801480# are specified, then all dataobjs are deleted.
    14811481# ----------------------------------------------------------------------
    1482 itcl::body Rappture::MolvisViewer::delete {args} {
     1482itcl::body Rappture::MolvisViewer::delete { args } {
    14831483    if {[llength $args] == 0} {
    14841484        set args $_dlist
  • trunk/gui/scripts/visviewer.tcl

    r1448 r1483  
    527527#
    528528itcl::body Rappture::VisViewer::SendEcho {channel {data ""}} {
    529     #puts stderr ">>$data"
     529    #puts stderr ">>($data)"
    530530    if {[string length $itk_option(-sendcommand)] > 0} {
    531531        uplevel #0 $itk_option(-sendcommand) [list $channel $data]
Note: See TracChangeset for help on using the changeset viewer.