Changeset 87b1c46 in tol


Ignore:
Timestamp:
Nov 15, 2016, 9:03:42 AM (10 years ago)
Author:
Pedro Gea <pgea@…>
Branches:
1941-docker-image-to-test, devel, master
Children:
4592f76
Parents:
06f7d3d
Message:

Refs #1933
Se sustituye BLT por RBC.
Se prescinde de otros widgets no usados, dependientes de BLT. (Véanse loadByswidget.tcl y pkgIndex.tcl)

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

Location:
tolbase/lib
Files:
9 edited

Legend:

Unmodified
Added
Removed
  • tolbase/lib/byswidget/bfunctions/bfsql.tcl

    r06f7d3d r87b1c46  
    485485  #NOTE:  move traces to "DBQuery"
    486486  . configure -cursor watch
    487   ::blt::busy hold .
     487  ::rbc::busy hold .
    488488  set lst {}
    489489  Tolcon_Trace "IniQuery: \
    … …  
    507507  Tolcon_Trace "EndQuery: [clock format [clock seconds] -format "%Y%m%d %T"]"
    508508  . configure -cursor ""
    509   ::blt::busy release .
     509  ::rbc::busy release .
    510510  update
    511511  return $lst
  • tolbase/lib/byswidget/bodbc/bodbc.tcl

    r06f7d3d r87b1c46  
    306306    # wait
    307307    if { 0 } {
    308       blt::busy hold $widget(dlg)
     308      rbc::busy hold $widget(dlg)
    309309      update
    310310    }
    … …  
    329329    # end wait
    330330    if { 0 } {
    331       blt::busy release $widget(dlg)
     331      rbc::busy release $widget(dlg)
    332332    }
    333333  }
  • tolbase/lib/byswidget/loadByswidget.tcl

    r06f7d3d r87b1c46  
    99package require bselectfields
    1010package require btoplevel
    11 package require btreeview
    12 package require btreeviewplus
     11#@!NO package require btreeview
     12#@!NO package require btreeviewplus
    1313package require bguifunction
    1414package require bmultiselect
  • tolbase/lib/byswidget/pkgIndex.tcl

    r06f7d3d r87b1c46  
    1818  bselectfields
    1919  btoplevel
    20   btreeview
    21   btreeviewplus
    2220  bguifunction
    2321  bmultiselect
    … …  
    2826  bdialog
    2927} {
    30   #@!NO: bsersel btab
     28  #@!NO: bsersel btab btreeview btreeviewplus
    3129  set dir [file join $maindir $d]
    3230  source [file join $dir pkgIndex.tcl]
  • tolbase/lib/toltk/bysgraph.tcl

    r06f7d3d r87b1c46  
    1616  package require Tk
    1717  package require BWidget
    18   package require BLT 
     18  package require RBC 
    1919  Bitmap::use
    2020  set toltk_script_path [file dirname [info script]]
    … …  
    3737#   tmpOpt  -> temporary array used to store the widgets and variables of the
    3838#              options dialog.
    39 #   instance -> asociative array of blt graph widget's path with the instance
     39#   instance -> asociative array of rbc graph widget's path with the instance
    4040#              of bayesGraph.
    4141#
    … …  
    138138  set i 0
    139139  foreach fr $panel {
    140     set widgets(gr,$i) [blt::graph $fr.gr]
     140    set widgets(gr,$i) [rbc::graph $fr.gr]
    141141    set instance($fr.gr) $Instance
    142142    pack $widgets(gr,$i) -fill both -expand yes
    … …  
    686686  proc ::bayesGraph::ZoomFrame { this } {
    687687#
    688 # PURPOSE: Sets zoom-frame mode for the blt graph
     688# PURPOSE: Sets zoom-frame mode for the rbc graph
    689689#     
    690690# PARAMETERS:
    … …  
    699699  proc ::bayesGraph::ZoomIn { this } {
    700700#
    701 # PURPOSE: Sets zoom-in mode for the blt graph
     701# PURPOSE: Sets zoom-in mode for the rbc graph
    702702#     
    703703# PARAMETERS:
    … …  
    713713  proc ::bayesGraph::ZoomOut { this } {
    714714#
    715 # PURPOSE: Sets zoom-out mode for the blt graph
     715# PURPOSE: Sets zoom-out mode for the rbc graph
    716716#     
    717717# PARAMETERS:
    … …  
    727727  proc ::bayesGraph::ScrollView { this } {
    728728#
    729 # PURPOSE: Sets scroll mode for the blt graph
     729# PURPOSE: Sets scroll mode for the rbc graph
    730730#     
    731731# PARAMETERS:
    … …  
    741741  proc ::bayesGraph::SetViewMode { this mode } {
    742742#
    743 # PURPOSE: Sets zoom (or scroll) mode for the blt graph. It also enables and
     743# PURPOSE: Sets zoom (or scroll) mode for the rbc graph. It also enables and
    744744#          disables toolbar buttons and sets cursors types acording to the
    745745#          mode choosen.
    … …  
    747747# PARAMETERS:
    748748#   this -> bayesgraph instance
    749 #   mode -> mode for the blt graph
     749#   mode -> mode for the rbc graph
    750750#
    751751#/////////////////////////////////////////////////////////////////////////////
    … …  
    766766    set item $widgets(gr,$gr)
    767767    $item configure -cursor $widgets(cursor,$active)
    768     Blt_ViewMode $item $active
     768    Rbc_ViewMode $item $active
    769769  }
    770770
    … …  
    837837    for  {set i 0} {$i<$data(gr,numGraph)} {incr i 1} {
    838838      set item $widgets(gr,$i)
    839       blt::Crosshairs $item
     839      rbc::Crosshairs $item
    840840    }   
    841841  } else {
    842842    for  {set i 0} {$i<$data(gr,numGraph)} {incr i 1} {
    843843      set item $widgets(gr,$i)
    844       blt::ClearCrosshairs $item
     844      rbc::ClearCrosshairs $item
    845845    }
    846846  }
  • tolbase/lib/toltk/graph.tcl

    r06f7d3d r87b1c46  
    11#/////////////////////////////////////////////////////////////////////////////
    22# FILE    : graph.tcl
    3 # PURPOSE : This file is part of BLT Toolkit
     3# PURPOSE : This file is part of RBC Toolkit
    44#/////////////////////////////////////////////////////////////////////////////
    55
    6 # force blt load
    7 
    8 if { [info command "_blt_InitStack"] eq "" } {
    9   blt::graph .__g__
    10   Blt_ZoomStack .__g__
     6# force rbc load
     7
     8if { [info command "_rbc_InitStack"] eq "" } {
     9  rbc::graph .__g__
     10  Rbc_ZoomStack .__g__
    1111  destroy .__g__
    12   rename blt::InitStack _blt_InitStack
     12  rename rbc::InitStack _rbc_InitStack
    1313}
    1414
    … …  
    2525}
    2626
    27 if { [ catch { blt::busy patched } ] } {
    28   rename ::blt::busy _blt_busy
    29   interp alias {} ::blt::busy {} Busy_Patched
    30   puts "interp alias {} ::blt::busy {} Busy_Patched"
     27if { [ catch { rbc::busy patched } ] } {
     28  rename ::rbc::busy _rbc_busy
     29  interp alias {} ::rbc::busy {} Busy_Patched
     30  puts "interp alias {} ::rbc::busy {} Busy_Patched"
    3131}
    3232
    … …  
    3939#   scroll
    4040
    41 proc Blt_ViewMode { graph mode } {
    42   global zoomInfo
    43 
    44   if { ![blt::ClearMode $graph $mode] } return
     41proc Rbc_ViewMode { graph mode } {
     42  global zoomInfo
     43
     44  if { ![rbc::ClearMode $graph $mode] } return
    4545
    4646  set zoomInfo($graph,mode) $mode
    … …  
    4848  if { [string equal $mode "scroll"] } {
    4949    # limpio el stack
    50     blt::InitStack $graph $mode
    51     bind scroll-$graph <ButtonPress-1> { blt::SetScrollPoint %W %x %y }
    52     bind scroll-$graph <ButtonRelease-1> { blt::SetScrollPoint %W %x %y }
     50    rbc::InitStack $graph $mode
     51    bind scroll-$graph <ButtonPress-1> { rbc::SetScrollPoint %W %x %y }
     52    bind scroll-$graph <ButtonRelease-1> { rbc::SetScrollPoint %W %x %y }
    5353    # este evento posiblemente ya no hara falta
    5454    bind scroll-$graph <ButtonPress-3> {
    5555      if { [%W inside %x %y] } {
    56         blt::ResetScroll %W
    57       }
    58     }
    59     blt::AddBindTag $graph scroll-$graph
     56        rbc::ResetScroll %W
     57      }
     58    }
     59    rbc::AddBindTag $graph scroll-$graph
    6060  } elseif { [regexp "zoom-*" $mode] } {
    6161    puts "mode = $mode"
    62     bind zoom-$graph <ButtonPress-1> { blt::SetZoomPoint %W %x %y }
     62    bind zoom-$graph <ButtonPress-1> { rbc::SetZoomPoint %W %x %y }
    6363    if { [string equal $mode zoom-frame] } {
    64       bind zoom-$graph <ButtonRelease-1> { blt::SetZoomPoint %W %x %y }
     64      bind zoom-$graph <ButtonRelease-1> { rbc::SetZoomPoint %W %x %y }
    6565    } else {
    6666      bind zoom-$graph <ButtonRelease-1> ""
    … …  
    6868    bind zoom-$graph <ButtonPress-3> {
    6969      if { [%W inside %x %y] } {
    70         blt::ResetZoom %W
    71       }
    72     }
    73     blt::AddBindTag $graph zoom-$graph
    74   }
    75 }
    76 
    77 proc blt::RemoveBindTag { widget args } {
     70        rbc::ResetZoom %W
     71      }
     72    }
     73    rbc::AddBindTag $graph zoom-$graph
     74  }
     75}
     76
     77proc rbc::RemoveBindTag { widget args } {
    7878  set oldTagList [bindtags $widget]
    7979  foreach tag $args {
    … …  
    8585}
    8686
    87 proc blt::InitStack { graph {mode zoom-frame} } {
     87proc rbc::InitStack { graph {mode zoom-frame} } {
    8888    global zoomInfo
    8989 
    90     _blt_InitStack $graph
     90    _rbc_InitStack $graph
    9191    # this is to allow zoom in, out scroll
    9292 
    … …  
    9595
    9696
    97 proc blt::SetZoomScale { graph scale } {
     97proc rbc::SetZoomScale { graph scale } {
    9898  global zoomInfo
    9999
    … …  
    101101}
    102102
    103 proc blt::ClearMode { graph newmode } {
     103proc rbc::ClearMode { graph newmode } {
    104104  global zoomInfo
    105105
    … …  
    111111    if { [string equal $zoomInfo($graph,mode) "scroll"] } {
    112112      eval $graph marker delete [$graph marker names "scroll*"]
    113       blt::RemoveBindTag $graph "scroll-region-$graph" "scroll-$graph"
     113      rbc::RemoveBindTag $graph "scroll-region-$graph" "scroll-$graph"
    114114    } else {
    115115      eval $graph marker delete [$graph marker names "zoom*"]
    116       blt::RemoveBindTag $graph "select-region-$graph" "zoom-$graph"
    117     }
    118   } else {
    119     blt::InitStack $graph ""
     116      rbc::RemoveBindTag $graph "select-region-$graph" "zoom-$graph"
     117    }
     118  } else {
     119    rbc::InitStack $graph ""
    120120  }
    121121  return 1
    122122}
    123123
    124 proc blt::ZoomScale { graph } {
     124proc rbc::ZoomScale { graph } {
    125125  global zoomInfo
    126126
    … …  
    166166}
    167167
    168 proc blt::SetZoomPoint { graph x y } {
     168proc rbc::SetZoomPoint { graph x y } {
    169169  global zoomInfo zoomMod
    170170  if { ![info exists zoomInfo($graph,corner)] } {
    171     blt::InitStack $graph
    172   }
    173   blt::GetCoords $graph $x $y $zoomInfo($graph,corner)
    174 
    175   #puts  blt::SetZoomPoint
     171    rbc::InitStack $graph
     172  }
     173  rbc::GetCoords $graph $x $y $zoomInfo($graph,corner)
     174
     175  #puts  rbc::SetZoomPoint
    176176
    177177  if { [string compare $zoomInfo($graph,mode) "zoom-frame"] } {
    178     blt::ZoomScale $graph
     178    rbc::ZoomScale $graph
    179179    return
    180180  }
    … …  
    186186  }
    187187  bind select-region-$graph <${modifier}Motion> {
    188     blt::GetCoords %W %x %y B
    189     #blt::MarkPoint $graph B
    190     blt::Box %W
     188    rbc::GetCoords %W %x %y B
     189    #rbc::MarkPoint $graph B
     190    rbc::Box %W
    191191  }
    192192  if { $zoomInfo($graph,corner) == "A" } {
    … …  
    196196        # First corner selected, start watching motion events
    197197
    198         #blt::MarkPoint $graph A
    199         blt::ZoomTitleNext $graph
    200 
    201         blt::AddBindTag $graph select-region-$graph
     198        #rbc::MarkPoint $graph A
     199        rbc::ZoomTitleNext $graph
     200
     201        rbc::AddBindTag $graph select-region-$graph
    202202        set zoomInfo($graph,corner) B
    203203  } else {
    204204        # Delete the modal binding
    205         blt::RemoveBindTag $graph select-region-$graph
    206         blt::PushZoom $graph
     205        rbc::RemoveBindTag $graph select-region-$graph
     206        rbc::PushZoom $graph
    207207        set zoomInfo($graph,corner) A
    208208  }
    209209}
    210210
    211 proc blt::SetScrollPoint { graph x y } {
     211proc rbc::SetScrollPoint { graph x y } {
    212212    global zoomInfo
    213213
    214     blt::GetCoords $graph $x $y A
     214    rbc::GetCoords $graph $x $y A
    215215    bind scroll-region-$graph <Any-Motion> {
    216         blt::GetCoords %W %x %y B
    217         #blt::MarkPoint $graph B
    218         blt::Scroll %W
     216        rbc::GetCoords %W %x %y B
     217        #rbc::MarkPoint $graph B
     218        rbc::Scroll %W
    219219    }
    220220    if { $zoomInfo($graph,corner) == "A" } {
    … …  
    224224        # First corner selected, start watching motion events
    225225
    226         #blt::MarkPoint $graph A
    227         blt::ScrollTitle $graph
    228 
    229         blt::AddBindTag $graph scroll-region-$graph
     226        #rbc::MarkPoint $graph A
     227        rbc::ScrollTitle $graph
     228
     229        rbc::AddBindTag $graph scroll-region-$graph
    230230        set zoomInfo($graph,corner) B
    231231    } else {
    … …  
    235235}
    236236
    237 proc blt::Scroll { graph } {
     237proc rbc::Scroll { graph } {
    238238  global zoomInfo
    239239
    … …  
    257257}
    258258
    259 proc blt::ResetScroll { graph } {
     259proc rbc::ResetScroll { graph } {
    260260  global zoomInfo
    261261
    262262  eval $graph marker delete [$graph marker names "scroll*"]
    263   blt::RemoveBindTag $graph scroll-region-$graph
     263  rbc::RemoveBindTag $graph scroll-region-$graph
    264264  set zoomInfo($graph,corner) A 
    265265}
    266266
    267 proc blt::ScrollTitle { graph } {
     267proc rbc::ScrollTitle { graph } {
    268268    if { [$graph cget -invertxy] } {
    269269        set coords "-Inf -Inf"
  • tolbase/lib/toltk/odbc.tcl

    r06f7d3d r87b1c46  
    225225  variable tmpdata
    226226
    227   blt::busy hold $tmpdata(dlg)
     227  rbc::busy hold $tmpdata(dlg)
    228228  update
    229229  if [catch "database dbtest $tmpdata(alias) $tmpdata(user) $tmpdata(password)" msg] {
    … …  
    249249    $tmpdata(dlg) enddialog ok
    250250  }
    251   blt::busy release $tmpdata(dlg)
     251  rbc::busy release $tmpdata(dlg)
    252252}
    253253
  • tolbase/lib/toltk/sergraph.tcl

    r06f7d3d r87b1c46  
    3232        ::SeriesGraph::ShowSerieInfo %I %W %x %y
    3333      } ]
    34   blt::AddBindTag $graph closest-point-$graph
     34  rbc::AddBindTag $graph closest-point-$graph
    3535 
    3636}
  • tolbase/lib/toltk/setgraph.tcl

    r06f7d3d r87b1c46  
    430430#
    431431# PARAMETERS:
    432 #   path     -> path of the blt graph
     432#   path     -> path of the rbc graph
    433433#   tableset -> command of the set
    434434#   set      -> reference to the TOL set
    … …  
    511511#
    512512# PARAMETERS:
    513 #   path     -> path of the blt graph
     513#   path     -> path of the rbc graph
    514514#   tableset -> command of the set
    515515#   set      -> reference to the TOL set
    … …  
    542542#///////////////////////////////////////////////////////////////////////////// 
    543543  if [llength $list] {
    544     eval blt::vector destroy $list
     544    eval rbc::vector destroy $list
    545545  }
    546546}
    … …  
    11561156  proc ::SetGraphDialog::Finish {dialog} {
    11571157#
    1158 # PURPOSE: Creates the blt vectors acording to the columns selection done by
     1158# PURPOSE: Creates the rbc vectors acording to the columns selection done by
    11591159#          the user. It also get the maximun and minimun x value of the
    11601160#          selected series
    … …  
    11721172  proc ::SetGraphDialog::SetSelection {} {
    11731173#
    1174 # PURPOSE: Creates the blt vectors acording to the columns selection done by
     1174# PURPOSE: Creates the rbc vectors acording to the columns selection done by
    11751175#          the user. It also get the maximun and minimun x value of the
    11761176#          selected series
Note: See TracChangeset for help on using the changeset viewer.