- Timestamp:
- Jan 12, 2012, 3:45:04 PM (13 years ago)
- Location:
- trunk/gui
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gui/apps/about.in
r2415 r2762 20 20 # ====================================================================== 21 21 #\ 22 . rappture.env \ 22 dir=`dirname $0` \ 23 . $dir/rappture.env \ 23 24 exec wish "$0" $* 24 25 # ---------------------------------------------------------------------- -
trunk/gui/scripts/barchartresult.tcl
r2566 r2762 912 912 set tip "" 913 913 if {$state == "at"} { 914 set state 0 914 915 if {[$g element closest $x $y info -interpolate yes]} { 915 916 # for dealing with xy line plots 916 917 set elem $info(name) 917 918 918 919 # Some elements are generated dynamically and therefore will 919 920 # not have a dataobj associated with them. … … 923 924 foreach {mapx mapy} [_getAxes $_elem2dataobj($elem)] break 924 925 } 925 926 926 927 # search again for an exact point -- this time don't interpolate 927 928 set tip "" 928 929 array unset info 929 930 if {[$g element closest $x $y info -interpolate no] 930 931 931 && $info(name) == $elem} { 932 932 933 set x [$g axis transform $mapx $info(x)] 933 934 set y [$g axis transform $mapy $info(y)] … … 952 953 # for dealing with xy scatter plot 953 954 set elem $info(name) 954 955 955 956 # Some elements are generated dynamically and therefore will 956 957 # not have a dataobj associated with them. … … 960 961 foreach {mapx mapy} [_getAxes $_elem2dataobj($elem)] break 961 962 } 962 963 963 964 set tip "" 964 965 set x [$g axis transform $mapx $info(x)] 965 966 set y [$g axis transform $mapy $info(y)] 966 967 if {[info exists _elem2dataobj($elem)]} { 968 set dataobj $_elem2dataobj($elem) 969 set yunits [$dataobj hints yunits] 970 set xunits [$dataobj hints xunits] 971 } else { 972 set xunits "" 973 set yunits "" 974 } 975 set tip [$g element cget $elem -label] 976 set yval [_axis format y dummy $info(y)] 977 append tip "\n$yval$yunits" 978 set xval [_axis format x dummy $info(x)] 979 append tip " @ $xval$xunits" 980 set tip [string trim $tip] 981 set state 1 982 } else { 983 set state 0 984 } 985 } 986 } 987 988 if {$state} { 967 968 if {[info exists _elem2dataobj($elem)]} { 969 set dataobj $_elem2dataobj($elem) 970 set yunits [$dataobj hints yunits] 971 set xunits [$dataobj hints xunits] 972 } else { 973 set xunits "" 974 set yunits "" 975 } 976 set tip [$g element cget $elem -label] 977 set yval [_axis format y dummy $info(y)] 978 append tip "\n$yval$yunits" 979 set xval [_axis format x dummy $info(x)] 980 append tip " @ $xval$xunits" 981 set tip [string trim $tip] 982 set state 1 983 } 984 } else { 985 set state 0 986 } 987 988 if { $state } { 989 989 # 990 990 # Highlight ON: … … 1490 1490 itcl::body Rappture::BarchartResult::_getLineMarkerOptions {style} { 1491 1491 array set lineOptions { 1492 "-color" "- color"1492 "-color" "-outline" 1493 1493 "-dashes" "-dashes" 1494 1494 "-linecolor" "-foreground" -
trunk/gui/scripts/vtkstreamlinesviewer.tcl
r2756 r2762 80 80 protected method Rotate {option x y} 81 81 protected method SendCmd {string} 82 protected method SendCmdNo Wait{string}82 protected method SendCmdNoSplash {string} 83 83 protected method Zoom {option} 84 84 … … 890 890 891 891 # 892 # SendCmdNoWait 893 # 894 # Send commands off to the rendering server. If we're currently 895 # sending data objects to the server, buffer the commands to be 896 # sent later. 897 # 898 itcl::body Rappture::VtkStreamlinesViewer::SendCmdNoWait {string} { 892 # SendCmdNoSplash 893 # 894 # Send commands off to the rendering server. This method 895 # doesn't initiate the slash screen. 896 # 897 itcl::body Rappture::VtkStreamlinesViewer::SendCmdNoSplash {string} { 899 898 if { $_buffering } { 900 899 append _outbuf $string "\n" … … 1285 1284 itcl::body Rappture::VtkStreamlinesViewer::Pick {x y} { 1286 1285 foreach tag [CurrentDatasets -visible] { 1287 SendCmd "dataset getscalar pixel $x $y $tag"1286 SendCmdNoSplash "dataset getscalar pixel $x $y $tag" 1288 1287 } 1289 1288 } … … 1606 1605 foreach {dataobj comp} [split $dataset -] break 1607 1606 if { [info exists _dataset2style($dataset)] } { 1608 SendCmdNo Wait\1607 SendCmdNoSplash \ 1609 1608 "legend $_dataset2style($dataset) $_colorMode $name {} $w $h 0" 1610 1609 break; -
trunk/gui/src/RpConvertDxToVtk.c
r2730 r2762 46 46 47 47 static int 48 GetPoints(Tcl_Interp *interp, int nPoints, char **stringPtr,48 GetPoints(Tcl_Interp *interp, int nPoints, int *counts, char **stringPtr, 49 49 const char *endPtr, Tcl_Obj *objPtr) 50 50 { … … 54 54 char mesg[2000]; 55 55 float *array, scale, vmin, vmax; 56 int iX, iY, iZ; 56 57 57 58 nValues = 0; … … 62 63 } 63 64 vmin = FLT_MAX, vmax = -FLT_MAX; 65 iX = iY = iZ = 0; 64 66 for (i = 0; i < nPoints; i++) { 65 67 double value; 66 68 char *nextPtr; 67 69 int loc; 70 68 71 if (p >= endPtr) { 69 72 Tcl_AppendResult(interp, "unexpected EOF in reading points", … … 78 81 } 79 82 p = nextPtr; 80 array[i] = value; 83 loc = iZ*counts[0]*counts[1] + iY*counts[0] + iX; 84 if (++iZ >= counts[2]) { 85 iZ = 0; 86 if (++iY >= counts[1]) { 87 iY = 0; 88 ++iX; 89 } 90 } 91 array[loc] = value; 81 92 if (value < vmin) { 82 93 vmin = value; … … 175 186 fprintf(stderr, "found delta %g %g %g\n", ddx, ddy, ddx); 176 187 #endif 188 } else if (sscanf(line, "object %*d class regulararray count %d", 189 count[2]) == 1) { 190 177 191 } else if (sscanf(line, "object %*d class array type %*s shape 3" 178 192 " rank 1 items %d data follows", &nPoints) == 1) { … … 191 205 return TCL_ERROR; 192 206 } 193 if (GetPoints(interp, nPoints, &p, pend, pointsObjPtr) != TCL_OK) { 207 if (GetPoints(interp, nPoints, count, &p, pend, pointsObjPtr) 208 != TCL_OK) { 194 209 return TCL_ERROR; 195 210 } … … 207 222 return TCL_ERROR; 208 223 } 209 if (GetPoints(interp, nPoints, &p, pend, pointsObjPtr) != TCL_OK) { 224 if (GetPoints(interp, nPoints, count, &p, pend, pointsObjPtr) 225 != TCL_OK) { 210 226 return TCL_ERROR; 211 227 }
Note: See TracChangeset
for help on using the changeset viewer.