TextSweep

Check-in [5df4848cd0]
Login

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

Overview
Comment:Update UI
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 5df4848cd017b84781a5df5ad9965a599e8051ac
User & Date: kevin 2017-02-09 13:21:21
Context
2017-03-25
02:04
Revbump to 3.1 check-in: 11d211a68d user: kevin tags: trunk
2017-02-09
13:21
Update UI check-in: 5df4848cd0 user: kevin tags: trunk
2016-09-13
13:16
Fix in Mac build script check-in: 78a8a4f2f4 user: kevin tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to Info-cbk.plist.

11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
        <key>NSPrincipalClass</key>
        <string>NSApplication</string>
<key>NSHighResolutionCapable</key>
	<true/>
	<key>LSMinimumSystemVersionByArchitecture</key>
	<dict>
	<key>i386</key>
	<string>10.9</string>
	<key>x86_64</key>
	<string>10.9</string>
	</dict>
	<key>LSArchitecturePriority</key>
<array>
<string>x86_64</string>
<string>i386</string>
</array>
	<key>LSApplicationCategoryType</key>







|

|







11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
        <key>NSPrincipalClass</key>
        <string>NSApplication</string>
<key>NSHighResolutionCapable</key>
	<true/>
	<key>LSMinimumSystemVersionByArchitecture</key>
	<dict>
	<key>i386</key>
	<string>10.11</string>
	<key>x86_64</key>
	<string>10.11</string>
	</dict>
	<key>LSArchitecturePriority</key>
<array>
<string>x86_64</string>
<string>i386</string>
</array>
	<key>LSApplicationCategoryType</key>
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
	<key>CFBundlePackageType</key>
	<string>APPL</string>
	<key>CFBundleShortVersionString</key>
	<string>3.0.0</string>
	<key>CFBundleVersion</key>
	<string>3.0.0</string>
	<key>LSMinimumSystemVersion</key>
	<string>10.9</string>
	<key>LSRequiresCarbon</key>
	<true/>	
	<key>NSSupportsAutomaticTermination</key>
	<string>YES</string>
	<key>NSSupportsSuddenTermination</key>
	<string>YES</string>
  <key>SUFeedURL</key>
	<string>http://www.codebykevin.com/textsweep.xml</string>
<key>SUPublicDSAKeyFile</key>
	<string>dsa_pub.pem</string>
</dict>
</plist>







|








<
<


56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71


72
73
	<key>CFBundlePackageType</key>
	<string>APPL</string>
	<key>CFBundleShortVersionString</key>
	<string>3.0.0</string>
	<key>CFBundleVersion</key>
	<string>3.0.0</string>
	<key>LSMinimumSystemVersion</key>
	<string>10.11</string>
	<key>LSRequiresCarbon</key>
	<true/>	
	<key>NSSupportsAutomaticTermination</key>
	<string>YES</string>
	<key>NSSupportsSuddenTermination</key>
	<string>YES</string>
  <key>SUFeedURL</key>
	<string>http://www.codebykevin.com/textsweep.xml</string>


</dict>
</plist>

Changes to buildapp.

1
2
3
4
5
6
7
8
9
10
11






12
13
14
15
16
17
18
#!/bin/sh

echo "Starting build process..."



if [ -a TextSweep.app ]
	then
	rm -rf TextSweep.app
fi







	
if [ -a build/TextSweep.app ]
	then
	rm -rf build/TextSweep.app
fi

#generate new plist file











>
>
>
>
>
>







1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/sh

echo "Starting build process..."



if [ -a TextSweep.app ]
	then
	rm -rf TextSweep.app
fi


if [ -a TextSweep.dmg ]
 then
    rm TextSweep.dmg
fi

	
if [ -a build/TextSweep.app ]
	then
	rm -rf build/TextSweep.app
fi

#generate new plist file
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
<plist version="1.0">
<dict>
	<key>CFBundleDevelopmentRegion</key>
	<string>English</string>
	<key>CFBundleExecutable</key>
	<string>TextSweep</string>
	<key>CFBundleGetInfoString</key>
	<string>TextSweep $1 (c) 2014 WordTech Communications LLC</string>
        <key>NSPrincipalClass</key>
        <string>NSApplication</string>
<key>NSHighResolutionCapable</key>
	<true/>
	<key>LSMinimumSystemVersionByArchitecture</key>
	<dict>
	<key>i386</key>
	<string>10.9</string>
	<key>x86_64</key>
	<string>10.9</string>
	</dict>
	<key>LSArchitecturePriority</key>
<array>
<string>x86_64</string>
<string>i386</string>
</array>
	<key>LSApplicationCategoryType</key>
	<string>public.app-category.utilities</string>
	<key>NSHumanReadableCopyright</key>
	<string>(c) 2014 WordTech Communications LLC</string>
	<key>CFBundleIconFile</key>
	<string>textsweep.icns</string>
	<key>CFBundleInfoDictionaryVersion</key>
	<string>6.0</string>
	<key>CFBundleDocumentTypes</key>
	<array>
		<dict>







|







|

|









|







32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
<plist version="1.0">
<dict>
	<key>CFBundleDevelopmentRegion</key>
	<string>English</string>
	<key>CFBundleExecutable</key>
	<string>TextSweep</string>
	<key>CFBundleGetInfoString</key>
	<string>TextSweep $1 (c) 2017 WordTech Communications LLC</string>
        <key>NSPrincipalClass</key>
        <string>NSApplication</string>
<key>NSHighResolutionCapable</key>
	<true/>
	<key>LSMinimumSystemVersionByArchitecture</key>
	<dict>
	<key>i386</key>
	<string>10.12</string>
	<key>x86_64</key>
	<string>10.12</string>
	</dict>
	<key>LSArchitecturePriority</key>
<array>
<string>x86_64</string>
<string>i386</string>
</array>
	<key>LSApplicationCategoryType</key>
	<string>public.app-category.utilities</string>
	<key>NSHumanReadableCopyright</key>
	<string>(c) 2017 WordTech Communications LLC</string>
	<key>CFBundleIconFile</key>
	<string>textsweep.icns</string>
	<key>CFBundleInfoDictionaryVersion</key>
	<string>6.0</string>
	<key>CFBundleDocumentTypes</key>
	<array>
		<dict>
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
	<key>CFBundlePackageType</key>
	<string>APPL</string>
	<key>CFBundleShortVersionString</key>
	<string>$1</string>
	<key>CFBundleVersion</key>
	<string>$1</string>
	<key>LSMinimumSystemVersion</key>
	<string>10.9</string>
	<key>LSRequiresCarbon</key>
	<true/>	
	<key>NSSupportsAutomaticTermination</key>
	<string>YES</string>
	<key>NSSupportsSuddenTermination</key>
	<string>YES</string>
  <key>SUFeedURL</key>
	<string>http://www.codebykevin.com/textsweep.xml</string>
<key>SUPublicDSAKeyFile</key>
	<string>dsa_pub.pem</string>
</dict>
</plist>
EOT



#create app bundle shell from standalone Wish app







|








<
<







85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100


101
102
103
104
105
106
107
	<key>CFBundlePackageType</key>
	<string>APPL</string>
	<key>CFBundleShortVersionString</key>
	<string>$1</string>
	<key>CFBundleVersion</key>
	<string>$1</string>
	<key>LSMinimumSystemVersion</key>
	<string>10.12</string>
	<key>LSRequiresCarbon</key>
	<true/>	
	<key>NSSupportsAutomaticTermination</key>
	<string>YES</string>
	<key>NSSupportsSuddenTermination</key>
	<string>YES</string>
  <key>SUFeedURL</key>
	<string>http://www.codebykevin.com/textsweep.xml</string>


</dict>
</plist>
EOT



#create app bundle shell from standalone Wish app
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
find build/TextSweep.app -type f -name "*.dylib"  -exec codesign --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" {} \; 
codesign  --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" build/TextSweep.app/Contents/Frameworks/Tk.framework/Versions/8.6/Resources/Wish.app/Contents/MacOS/Wish
codesign  --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" build/TextSweep.app/Contents/Frameworks/Tk.framework/Versions/Current
codesign --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" build/TextSweep.app/Contents/Frameworks/Tcl.framework/Versions/Current
codesign  --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" --verbose=2  build/TextSweep.app


#create tarball for update from website
echo "Compressing application..."

cd build
tar cvfz ../TextSweep.tgz TextSweep.app

cd ../

SIZE=$(stat -f %z TextSweep.tgz)
PUBDATE=$(date +"%a, %d %b %G %T %z")


RELEASE_NOTES=$(cat changelog.txt)

cat << EOT > TextSweep.xml
<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:sparkle="http://www.andymatuschak.org/xml-namespaces/sparkle" version="2.0">
  <channel>
    <title>TextSweep</title>
    <link>http://www.codebykevin.com/textsweep.html</link>
    <language>en</language>
    <item>

      <title>TextSweep $1</title>
      <sparkle:minimumSystemVersion>10.11</sparkle:minimumSystemVersion>
      <pubDate>$PUBDATE</pubDate>
      <author>Code by Kevin</author>
      <description><![CDATA[
This version of TextSweep has the following features and improvements:
$RELEASE_NOTES
      ]]></description>
      <link>http://www.codebykevin.com/textsweep.html</link>
     <enclosure
				url="http://www.codebykevin.com/updates/TextSweep.tgz"
				sparkle:version="$1"
				type="application/octet-stream"
				length="$SIZE"
			/>
    </item>

  </channel>
</rss>
EOT

if [ $2 == "release" ]
then

 echo "Building disk image and uploading to Amazon..."

 
 cd build
 zip -r -y TextSweep.zip TextSweep.app

 cd ../

 echo "Copying app and XML file to server..."
cp -f TextSweep.tgz /Users/kevin/share/kevin/Sites/codebykevin/updates/TextSweep.tgz
cp -f textsweep.xml  /Users/kevin/share/kevin/Sites/codebykevin/textsweep.xml

echo "Copying zip to Amazon S3..."
aws s3 cp build/TextSweep.zip s3://codebykevin/TextSweep.zip --acl public-read



cd ../

#create archive of entire source tree
tar cvfz TextSweep-$1.tgz TextSweep

fi

echo "Done."










<
<
<
<
|

<
|
<
<

|
<

|
<
<
<
<
<
<
<

|
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<

<
<
<
|
<
<

<
|
|
<
<

<

<
|
|
<
<
<
<
<






|





139
140
141
142
143
144
145




146
147

148


149
150

151
152







153
154















155



156


157

158
159


160

161

162
163





164
165
166
167
168
169
170
171
172
173
174
175
find build/TextSweep.app -type f -name "*.dylib"  -exec codesign --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" {} \; 
codesign  --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" build/TextSweep.app/Contents/Frameworks/Tk.framework/Versions/8.6/Resources/Wish.app/Contents/MacOS/Wish
codesign  --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" build/TextSweep.app/Contents/Frameworks/Tk.framework/Versions/Current
codesign --verbose --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" build/TextSweep.app/Contents/Frameworks/Tcl.framework/Versions/Current
codesign  --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" --verbose=2  build/TextSweep.app






xattr -cr build/TextSweep.app


codesign  --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" --verbose=2  build/TextSweep.app



echo "Creating and signing DMG file..."


hdiutil create  -srcfolder build -fs HFS+ -volname TextSweep TextSweep.dmg








codesign  --signature-size 9400 -f -s "Developer ID Application: Kevin Walzer" --verbose=2  TextSweep.dmg



















echo "Uploading DMG..."




cp -f TextSweep.dmg /Users/kevin/share/kevin/Sites/codebykevin/updates/TextSweep.dmg







cp -f textsweep-changes.tcl /Users/kevin/share/kevin/Sites/codebykevin/textsweep-changes.tcl
cp -f textsweep-version.tcl /Users/kevin/share/kevin/Sites/codebykevin/textsweep-version.tcl






cd ../

#create archive of entire source tree
tar cvfz TextSweep-$1.tgz TextSweep



echo "Done."



Changes to scriptlibs/textsweep/textsweep-main.tcl.

91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
#"about application" command
proc tkAboutDialog {} {
    aboutWindow
}

proc aboutWindow {} {

    set w .aboutw
    catch {destroy $w}
    toplevel $w 
    wm title $w "About TextSweep"


    frame $w.ftext 
    label $w.l -image logo -bg gray95

    pack $w.l -in $w -side top -expand no -fill both 
    pack $w.ftext -in $w -side bottom -expand no -fill both 

    text $w.ftext.text -yscrollcommand "$w.ftext.sbar set" \
        -wrap word -font TkDefaultFont -relief flat -bg gray95 -highlightbackground gray95
    scrollbar $w.ftext.sbar -takefocus 0 -command "$w.ftext.text yview"
    
    pack $w.ftext.text -in $w.ftext -side left -fill both -expand no
    pack $w.ftext.sbar -in $w.ftext -side right -fill y

    $w.ftext.text tag configure center -justify center
    $w.ftext.text tag configure bold -font {-weight bold}
    $w.ftext.text tag configure url -foreground blue
    $w.ftext.text tag bind url <ButtonPress-1> {
	xplat::launch "http://www.codebykevin.com/TextSweep.html"
    }

    
    $w.ftext.text insert end "TextSweep $appname::version\n" "bold center"
    $w.ftext.text insert end "Powerful Search and Replace\n\n" center
    $w.ftext.text insert end "Copyright (c) 2016 WordTech Communications LLC\n\n" center
    $w.ftext.text insert end "http://www.codebykevin.com/TextSweep.html\n\n" "url center"
    $w.ftext.text insert end "See Acknowledgements in TextSweep Help for additional credits and see History in TextSweep Help for changes in this version\n" center
    
    $w.ftext.text config -state disabled

    if {[tk windowingsystem] eq "aqua"} {
	bind $w <[xplat::controlkey]-W> [list wm withdraw $w]
	bind $w <[xplat::controlkey]-w> [list wm withdraw $w]
    }

    wm geometry $w 305x280


}

#check file list to ensure existence
proc checkfilelist {} {








<
<
<
<
|
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<







91
92
93
94
95
96
97




98




































99
100
101
102
103
104
105
#"about application" command
proc tkAboutDialog {} {
    aboutWindow
}

proc aboutWindow {} {





   tk_messageBox -parent . -icon info -title "About TextSweep" -message "TextSweep: Search and Replace Tool" -detail "Version x\n(c)2017 WordTech Communications LLC"






































}

#check file list to ensure existence
proc checkfilelist {} {

Changes to textsweep.xml.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:sparkle="http://www.andymatuschak.org/xml-namespaces/sparkle" version="2.0">
  <channel>
    <title>TextSweep</title>
    <link>http://www.codebykevin.com/textsweep.html</link>
    <language>en</language>
    <item>

      <title>TextSweep 3.0.0</title>
      <sparkle:minimumSystemVersion>10.11</sparkle:minimumSystemVersion>
      <pubDate>Sun, 04 Sep 2016 22:23:07 -0400</pubDate>
      <author>Code by Kevin</author>
      <description><![CDATA[
This version of TextSweep has the following features and improvements:
 * Initial Windows release.
 * UI refinements.
      ]]></description>
      <link>http://www.codebykevin.com/textsweep.html</link>
     <enclosure
				url="http://www.codebykevin.com/updates/TextSweep.tgz"
				sparkle:version="3.0.0"
				type="application/octet-stream"
				length="8020780"
			/>
    </item>

  </channel>
</rss>










|











|





1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:sparkle="http://www.andymatuschak.org/xml-namespaces/sparkle" version="2.0">
  <channel>
    <title>TextSweep</title>
    <link>http://www.codebykevin.com/textsweep.html</link>
    <language>en</language>
    <item>

      <title>TextSweep 3.0.0</title>
      <sparkle:minimumSystemVersion>10.11</sparkle:minimumSystemVersion>
      <pubDate>Wed, 14 Sep 2016 08:48:07 -0400</pubDate>
      <author>Code by Kevin</author>
      <description><![CDATA[
This version of TextSweep has the following features and improvements:
 * Initial Windows release.
 * UI refinements.
      ]]></description>
      <link>http://www.codebykevin.com/textsweep.html</link>
     <enclosure
				url="http://www.codebykevin.com/updates/TextSweep.tgz"
				sparkle:version="3.0.0"
				type="application/octet-stream"
				length="10242687"
			/>
    </item>

  </channel>
</rss>