Eskil

Check-in [ae796cb610]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Added tkdnd support.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | table-list
Files: files | file ages | folders
SHA1: ae796cb6105fbf8cfcf11bd0ec531348b58f8029
User & Date: peter.spjuth@gmail.com 2010-11-07 19:13:42
Context
2010-11-07
20:13
Snapshot release check-in: cc42e32283 user: peter.spjuth@gmail.com tags: table-list
19:13
Added tkdnd support. check-in: ae796cb610 user: peter.spjuth@gmail.com tags: table-list
18:37
Autodetect line endings in conflict file. Allow line ending selection in merge save. [FR 5160] Added menu bar to merge window. check-in: 5995a4b5f7 user: peter.spjuth@gmail.com tags: table-list
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to Changes.




1
2
3
4
5
6
7



2010-11-07
 Autodetect line endings in conflict file.
 Allow line ending selection in merge save. [FR 5160]
 Added menu bar to merge window.

2010-06-23
 Support -noempty from DiffUtil, to try it out.
>
>
>







1
2
3
4
5
6
7
8
9
10
2010-11-07
 Added tkdnd support. [FR 5125]

2010-11-07
 Autodetect line endings in conflict file.
 Allow line ending selection in merge save. [FR 5160]
 Added menu bar to merge window.

2010-06-23
 Support -noempty from DiffUtil, to try it out.

Changes to Makefile.

17
18
19
20
21
22
23

24
25
26
27
28
29
30
..
54
55
56
57
58
59
60


61
62
63
64
65
66
67
..
74
75
76
77
78
79
80

81
82
83
84
85
86
87
GRIFFIN    = /home/peter/tclkit/griffin.vfs/lib/griffin
TEXTSEARCH = /home/peter/src/textsearch
DIFFUTIL   = /home/peter/src/DiffUtilTcl/lib.vfs/DiffUtil
WCB        = /home/peter/src/packages/wcb3.0
PDF4TCL    = /home/peter/src/pdf4tcl/trunk/pkg
SNIT       = /home/peter/tcl/tcllib/modules/snit
TWAPI      = /home/peter/src/twapi

#DIFFUTIL   = /home/peter/src/DiffUtil/tcl

# Tools
NAGELFAR    = nagelfar

all: setup

................................................................................
	cd eskil.vfs/lib ; ln -s $(GRIFFIN) griffin
eskil.vfs/lib/textsearch:
	cd eskil.vfs/lib ; ln -s $(TEXTSEARCH) textsearch
eskil.vfs/lib/diffutil:
	cd eskil.vfs/lib ; ln -s $(DIFFUTIL) diffutil
eskil.vfs/lib/pdf4tcl:
	cd eskil.vfs/lib ; ln -s $(PDF4TCL) pdf4tcl


eskil.vfs/lib/snit:
	cd eskil.vfs/lib ; mkdir snit
	cd eskil.vfs/lib/snit ; ln -s $(SNIT)/pkgIndex.tcl
	cd eskil.vfs/lib/snit ; ln -s $(SNIT)/snit.tcl
	cd eskil.vfs/lib/snit ; ln -s $(SNIT)/snit2.tcl
	cd eskil.vfs/lib/snit ; ln -s $(SNIT)/main2.tcl
	cd eskil.vfs/lib/snit ; ln -s $(SNIT)/main1.tcl
................................................................................
	eskil.vfs/COPYING\
	eskil.vfs/lib/griffin\
	eskil.vfs/lib/style\
	eskil.vfs/lib/textsearch\
	eskil.vfs/lib/diffutil\
	eskil.vfs/lib/pdf4tcl\
	eskil.vfs/lib/snit\

	eskil.vfs/lib/wcb

setup: links

#----------------------------------------------------------------
# Testing
#----------------------------------------------------------------







>







 







>
>







 







>







17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
..
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
..
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
GRIFFIN    = /home/peter/tclkit/griffin.vfs/lib/griffin
TEXTSEARCH = /home/peter/src/textsearch
DIFFUTIL   = /home/peter/src/DiffUtilTcl/lib.vfs/DiffUtil
WCB        = /home/peter/src/packages/wcb3.0
PDF4TCL    = /home/peter/src/pdf4tcl/trunk/pkg
SNIT       = /home/peter/tcl/tcllib/modules/snit
TWAPI      = /home/peter/src/twapi
TKDND      = /home/peter/tkdnd/lib/tkdnd1.0
#DIFFUTIL   = /home/peter/src/DiffUtil/tcl

# Tools
NAGELFAR    = nagelfar

all: setup

................................................................................
	cd eskil.vfs/lib ; ln -s $(GRIFFIN) griffin
eskil.vfs/lib/textsearch:
	cd eskil.vfs/lib ; ln -s $(TEXTSEARCH) textsearch
eskil.vfs/lib/diffutil:
	cd eskil.vfs/lib ; ln -s $(DIFFUTIL) diffutil
eskil.vfs/lib/pdf4tcl:
	cd eskil.vfs/lib ; ln -s $(PDF4TCL) pdf4tcl
eskil.vfs/lib/tkdnd:
	cd eskil.vfs/lib ; ln -s $(TKDND) tkdnd
eskil.vfs/lib/snit:
	cd eskil.vfs/lib ; mkdir snit
	cd eskil.vfs/lib/snit ; ln -s $(SNIT)/pkgIndex.tcl
	cd eskil.vfs/lib/snit ; ln -s $(SNIT)/snit.tcl
	cd eskil.vfs/lib/snit ; ln -s $(SNIT)/snit2.tcl
	cd eskil.vfs/lib/snit ; ln -s $(SNIT)/main2.tcl
	cd eskil.vfs/lib/snit ; ln -s $(SNIT)/main1.tcl
................................................................................
	eskil.vfs/COPYING\
	eskil.vfs/lib/griffin\
	eskil.vfs/lib/style\
	eskil.vfs/lib/textsearch\
	eskil.vfs/lib/diffutil\
	eskil.vfs/lib/pdf4tcl\
	eskil.vfs/lib/snit\
	eskil.vfs/lib/tkdnd\
	eskil.vfs/lib/wcb

setup: links

#----------------------------------------------------------------
# Testing
#----------------------------------------------------------------

Changes to src/eskil.tcl.

35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
....
1962
1963
1964
1965
1966
1967
1968



































1969
1970
1971
1972
1973
1974
1975
....
2750
2751
2752
2753
2754
2755
2756






2757
2758
2759
2760
2761
2762
2763
# Stop Tk from meddling with the command line by copying it first.
set ::eskil(argv) $::argv
set ::eskil(argc) $::argc
set ::argv {}
set ::argc 0

set debug 1
set diffver "Version 2.4+ 2010-04-27"
set ::thisScript [file join [pwd] [info script]]

namespace import tcl::mathop::+
namespace import tcl::mathop::-
namespace import tcl::mathop::*
namespace import tcl::mathop::/

................................................................................
        if {[doOpenRight $top $forget]} {
            set ::diff($top,mode) ""
            set ::diff($top,mergeFile) ""
            doDiff $top
        }
    }
}




































#####################################
# GUI stuff
#####################################

# A little helper to make a scrolled window
# It returns the name of the scrolled window
................................................................................
    commonYScroll $top.sby $top.ft1.tl $top.ft1.tt $top.ft2.tl $top.ft2.tt

    # Set up a tag for incremental search bindings
    if {[info procs textSearch::enableSearch] != ""} {
        textSearch::enableSearch $top.ft1.tt -label ::widgets($top,isearchLabel)
        textSearch::enableSearch $top.ft2.tt -label ::widgets($top,isearchLabel)
    }







    ttk::label $top.le -textvariable ::widgets($top,eqLabel) -width 1
    addBalloon $top.le "* means external diff is running.\n= means files do\
            not differ.\n! means a large block is being processed.\nBlank\
            means files differ."
    # FIXA: verify that this label is ok after Tile migration
    ttk::label $top.ls -width 1 \







|







 







>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







 







>
>
>
>
>
>







35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
....
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
....
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798
2799
2800
2801
2802
2803
2804
# Stop Tk from meddling with the command line by copying it first.
set ::eskil(argv) $::argv
set ::eskil(argc) $::argc
set ::argv {}
set ::argc 0

set debug 1
set diffver "Version 2.4+ 2010-11-07"
set ::thisScript [file join [pwd] [info script]]

namespace import tcl::mathop::+
namespace import tcl::mathop::-
namespace import tcl::mathop::*
namespace import tcl::mathop::/

................................................................................
        if {[doOpenRight $top $forget]} {
            set ::diff($top,mode) ""
            set ::diff($top,mergeFile) ""
            doDiff $top
        }
    }
}

# File drop using TkDnd
proc fileDrop {top side files} {
    # FIXA: Maybe single drop during rev mode should stay in rev mode?
    # Dropping two files mean set both
    if {[llength $files] >= 2} {
        set leftFile [lindex $files 0]
        set rightFile [lindex $files 1]
    } elseif {$side eq "left"} {
        set leftFile [lindex $files 0]
        set rightFile ""
    } else {
        set leftFile ""
        set rightFile [lindex $files 0]
    }
    if {$leftFile ne ""} {
        set ::diff($top,leftDir) [file dirname $leftFile]
        set ::diff($top,leftFile) $leftFile
        set ::diff($top,leftLabel) $leftFile
        set ::diff($top,leftOK) 1
        set ::diff($top,mode) ""
        set ::diff($top,mergeFile) ""
    }
    if {$rightFile ne ""} {
        set ::diff($top,rightDir) [file dirname $rightFile]
        set ::diff($top,rightFile) $rightFile
        set ::diff($top,rightLabel) $rightFile
        set ::diff($top,rightOK) 1
        set ::diff($top,mode) ""
        set ::diff($top,mergeFile) ""
    }
    if {$::diff($top,leftOK) && $::diff($top,rightOK)} {
        doDiff $top
    }
}

#####################################
# GUI stuff
#####################################

# A little helper to make a scrolled window
# It returns the name of the scrolled window
................................................................................
    commonYScroll $top.sby $top.ft1.tl $top.ft1.tt $top.ft2.tl $top.ft2.tt

    # Set up a tag for incremental search bindings
    if {[info procs textSearch::enableSearch] != ""} {
        textSearch::enableSearch $top.ft1.tt -label ::widgets($top,isearchLabel)
        textSearch::enableSearch $top.ft2.tt -label ::widgets($top,isearchLabel)
    }

    # Set up file dropping in text windows if TkDnd is available
    if {![catch {package require tkdnd}]} {
        dnd bindtarget $top.ft1.tt text/uri-list <Drop> "fileDrop $top left %D"
        dnd bindtarget $top.ft2.tt text/uri-list <Drop> "fileDrop $top right %D"
    }

    ttk::label $top.le -textvariable ::widgets($top,eqLabel) -width 1
    addBalloon $top.le "* means external diff is running.\n= means files do\
            not differ.\n! means a large block is being processed.\nBlank\
            means files differ."
    # FIXA: verify that this label is ok after Tile migration
    ttk::label $top.ls -width 1 \