Ignore:
Timestamp:
Dec 4, 2011, 2:41:55 PM (15 years ago)
Author:
Jorge Pérez <josp.jorge@…>
Branches:
1941-docker-image-to-test, devel, master
Children:
a64f8ce
Parents:
af9a0af
Message:

fixes #1222

git-svn-id: ​https://www.tol-project.org/svn/tolp/trunk@3885 be4846ae-f051-483a-831f-b64e7d08527f

File:
1 edited

Legend:

Unmodified
Added
Removed
  • tolbase/lib/toltk/bysgropt.tcl

    raf9a0af r8d0dffc  
    32533253  }
    32543254  # marker each
     3255  puts "::bayesGraph::GrapOptApplyMarkers: $g, var=$var, pre=$pre"
     3256  puts "[ $g axis cget x -majorticks ]"
    32553257  foreach {axis map} {x mapx y mapy x2 mapx y2 mapy} {
    32563258    # comprobamos si esta visible el eje
    … …  
    32683270            # nos quedamos con el valor minimo y maximo del eje
    32693271            #TODO: igual es interesante quedarnos con el max y min de las lineas
    3270             #      asiciadas al eje
     3272            #      asociadas al eje
     3273            $g axis configure x -majorticks [ $g axis cger x -majorticks ]
     3274            if { 0 } {
    32713275            set max [$g axis cget $axis -max]
    32723276            set min [$g axis cget $axis -min]
    … …  
    32803284          }
    32813285          set i 0
     3286          }
    32823287          set j 0
     3288          puts "lstMarkers = $lstMarkers"
    32833289          foreach it $lstMarkers {
    32843290            if {$j==5} { set j 0 }
    … …  
    32923298            $g marker bind $it <Enter> \
    32933299                [list ::bayesGraph::WriteInfo $this "[mc Marker]${axis}: each $it"]
     3300            set majorTicks [ $g axis cget $axis -majorticks ]
    32943301            $g marker bind $it <Leave> \
    32953302                [list ::bayesGraph::WriteInfo $this ""]
     3303            puts "voy con it = $it"
     3304            for { set mt 0 } { $mt < [ llength $majorTicks ] } { incr mt } {
     3305              if { [ expr { ( $mt + 1 ) % int( $it ) } ] } continue
     3306              set pos [ lindex $majorTicks $mt ]
     3307              if { "x" eq [string index $axis 0] } {
     3308                set coord [list $pos -Inf $pos Inf]
     3309              } else {
     3310                set coord [list -Inf $pos Inf $pos]
     3311              }
     3312              puts "añadiendo marcador $mt en posicion $pos"
     3313              catch {
     3314                $g marker create line -name ${it}_$pos -coords $coord \
     3315                    -outline $color -dashes $dashe -$map $axis \
     3316                    -bindtags $it -linewidth $width -under $under
     3317              }
     3318            }
     3319            if { 0 } {
    32963320            while {$pos < $numTicks} {
    32973321              set pos [expr $pos + $it]
    … …  
    33073331            }
    33083332            incr i
     3333            }
    33093334          }
    33103335        }
    … …  
    33123337    }
    33133338  }
    3314 }
    3315 
     3339  puts "[ $g axis cget x -majorticks ]"
     3340}
    33163341
    33173342#/////////////////////////////////////////////////////////////////////////////
    … …  
    33413366          set lon [llength [$g marker names]]
    33423367          set j [expr $lon<5 ? $lon : $lon % 5]
    3343 
    33443368          foreach it $lstMarkersIn {
    33453369            if {$j==5} { set j 0 }
Note: See TracChangeset for help on using the changeset viewer.