Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | Added command line options to control PDF options. |
---|---|
Downloads: | Tarball | ZIP archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
a0e927608f20bde8d092d8ec8ecf12d0 |
User & Date: | peter.spjuth@gmail.com 2010-04-27 22:10:01.000 |
Context
2010-04-28
| ||
08:10 | Added some tests for new print command line options. check-in: 6f44793373 user: peter.spjuth@gmail.com tags: trunk | |
2010-04-27
| ||
22:10 | Added command line options to control PDF options. check-in: a0e927608f user: peter.spjuth@gmail.com tags: trunk | |
21:31 | Removed support for Postscript output. check-in: d83662d1cc user: peter.spjuth@gmail.com tags: trunk | |
Changes
Changes to Changes.
1 2 3 4 5 6 7 | 2010-04-27 Removed support for Postscript output. 2010-04-27 Handle an empty .eskilrc. [Bug 17113] Moved packages pstools and psballoon into GIT repository. | > > > | 1 2 3 4 5 6 7 8 9 10 | 2010-04-27 Added command line options to control PDF options. [FR 5008] 2010-04-27 Removed support for Postscript output. 2010-04-27 Handle an empty .eskilrc. [Bug 17113] Moved packages pstools and psballoon into GIT repository. |
︙ | ︙ |
Changes to doc/cmdline.txt.
︙ | ︙ | |||
45 46 47 48 49 50 51 | -conflict : Treat file as a merge conflict file and enter merge mode. -o <file> : Specify merge result output file. -browse : Automatically bring up file dialog after starting. -server : Set up Eskil to be controllable from the outside. | | > > > > > > | 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 | -conflict : Treat file as a merge conflict file and enter merge mode. -o <file> : Specify merge result output file. -browse : Automatically bring up file dialog after starting. -server : Set up Eskil to be controllable from the outside. -print <file> : Generate PDF and exit. -printCharsPerLine <n> : Adapt font size for this line length and wrap. (80) -printPaper <paper> : Select paper size (a4) -printHeaderSize <n> : Font size for page header (10) -printColorChange <RGB> : Color for change (1.0 0.7 0.7) -printColorOld <RGB> : Color for old text (0.7 1.0 0.7) -printColorNew <RGB : Color for new text (0.8 0.8 1.0) -plugin <name> : Preprocess files using plugin. -limit <lines> : Do not process more than <lines> lines.} To list all options matching a prefix, run 'eskil --query prefix'. In tcsh use this line to get option completion: |
︙ | ︙ |
Changes to src/eskil.tcl.
1 2 3 4 5 | #!/bin/sh #---------------------------------------------------------- -*- tcl -*- # # Eskil, a Graphical frontend to diff # | | | 1 2 3 4 5 6 7 8 9 10 11 12 13 | #!/bin/sh #---------------------------------------------------------- -*- tcl -*- # # Eskil, a Graphical frontend to diff # # Copyright (c) 1998-2010, Peter Spjuth (peter.spjuth@gmail.com) # # Usage # Do 'eskil' for interactive mode # Do 'eskil --help' for command line usage # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by |
︙ | ︙ | |||
35 36 37 38 39 40 41 | # 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 | | | 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 | # 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::/ |
︙ | ︙ | |||
3323 3324 3325 3326 3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 3341 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 | -limit <lines> : Do not process more than <lines> lines. To list all options matching a prefix, run 'eskil --query prefix'. In tcsh use this line to get option completion: complete eskil 'C/-/`eskil --query -`/'} } # Go through all command line arguments proc parseCommandLine {} { global dirdiff Pref set ::eskil(autoclose) 0 set ::eskil(ignorenewline) 0 if {$::eskil(argc) == 0} { Init makeDiffWin return } set allOpts { -w --help -help -b -noignore -i -nocase -nodigit -nokeyword -prefix -noparse -line -smallblock -block -char -word -limit -nodiff -dir -clip -patch -browse -conflict -print -server -o -r -context -cvs -svn -review -foreach -preprocess -close -nonewline -plugin -plugininfo -plugindump } # If the first option is "--query", use it to ask about options. if {$::eskil(argc) == 2 && [lindex $::eskil(argv) 0] == "--query"} { | > > > > > > > > > > > > > > > > > > > > | 3323 3324 3325 3326 3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 3341 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 | -limit <lines> : Do not process more than <lines> lines. To list all options matching a prefix, run 'eskil --query prefix'. In tcsh use this line to get option completion: complete eskil 'C/-/`eskil --query -`/'} } # Helper to validate command line option for color proc ValidatePdfColor {arg opt} { set fail 0 if {![string is list $arg] || [llength $arg] != 3} { set fail 1 } else { foreach val $arg { if {![string is double -strict $val] || $val < 0.0 || $val > 1.0} { set fail 1 } } } if {$fail} { puts "Argument $opt must be a list of RBG values from 0.0 to 1.0" exit } } # Go through all command line arguments proc parseCommandLine {} { global dirdiff Pref set ::eskil(autoclose) 0 set ::eskil(ignorenewline) 0 if {$::eskil(argc) == 0} { Init makeDiffWin return } set allOpts { -w --help -help -b -noignore -i -nocase -nodigit -nokeyword -prefix -noparse -line -smallblock -block -char -word -limit -nodiff -dir -clip -patch -browse -conflict -print -printHeaderSize -printCharsPerLine -printPaper -printColorChange -printColorOld -printColorNew -server -o -r -context -cvs -svn -review -foreach -preprocess -close -nonewline -plugin -plugininfo -plugindump } # If the first option is "--query", use it to ask about options. if {$::eskil(argc) == 2 && [lindex $::eskil(argv) 0] == "--query"} { |
︙ | ︙ | |||
3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 | foreach arg $::eskil(argv) { if {$nextArg != ""} { if {$nextArg eq "mergeFile"} { set opts(mergeFile) [file join [pwd] $arg] } elseif {$nextArg eq "printFile"} { set opts(printFile) [file join [pwd] $arg] } elseif {$nextArg eq "revision"} { set opts(doptrev$revNo) $arg incr revNo } elseif {$nextArg eq "limitlines"} { set opts(limitlines) $arg } elseif {$nextArg eq "context"} { set Pref(context) $arg | > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > | 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 3409 3410 3411 3412 3413 3414 3415 3416 3417 3418 3419 3420 3421 3422 3423 3424 3425 3426 3427 3428 3429 3430 3431 3432 3433 3434 3435 3436 3437 3438 3439 3440 3441 3442 | foreach arg $::eskil(argv) { if {$nextArg != ""} { if {$nextArg eq "mergeFile"} { set opts(mergeFile) [file join [pwd] $arg] } elseif {$nextArg eq "printFile"} { set opts(printFile) [file join [pwd] $arg] } elseif {$nextArg eq "printHeaderSize"} { if {![string is double -strict $arg] || $arg <= 0} { puts "Argument -printHeaderSize must be a positive number" exit } set Pref(printHeaderSize) $arg } elseif {$nextArg eq "printCharsPerLine"} { if {![string is integer -strict $arg] || $arg <= 0} { puts "Argument -printCharsPerLine must be a positive number" exit } set Pref(printCharsPerLine) $arg } elseif {$nextArg eq "printPaper"} { package require pdf4tcl if {[llength [pdf4tcl::getPaperSize $arg]] != 2} { puts "Argument -printPaper must be a valid paper size" puts "Valid paper sizes:" puts [join [lsort -dictionary [pdf4tcl::getPaperSizeList]] \n] exit } set Pref(printPaper) $arg } elseif {$nextArg eq "printColorChange"} { ValidatePdfColor $arg -printColorChange set Pref(printColorChange) $arg } elseif {$nextArg eq "printColorOld"} { ValidatePdfColor $arg -printColorOld set Pref(printColorNew1) $arg } elseif {$nextArg eq "printColorNew"} { ValidatePdfColor $arg -printColorNew set Pref(printColorNew2) $arg } elseif {$nextArg eq "revision"} { set opts(doptrev$revNo) $arg incr revNo } elseif {$nextArg eq "limitlines"} { set opts(limitlines) $arg } elseif {$nextArg eq "context"} { set Pref(context) $arg |
︙ | ︙ | |||
3500 3501 3502 3503 3504 3505 3506 3507 3508 3509 3510 3511 3512 3513 | set ::eskil(ignorenewline) 2 } elseif {$arg eq "-close"} { set ::eskil(autoclose) 1 } elseif {$arg eq "-conflict"} { set opts(mode) "conflict" } elseif {$arg eq "-print" || $arg eq "-printpdf"} { set nextArg printFile } elseif {$arg eq "-server"} { if {$::tcl_platform(platform) eq "windows"} { catch { package require dde dde servername Eskil } } else { | > > > | 3550 3551 3552 3553 3554 3555 3556 3557 3558 3559 3560 3561 3562 3563 3564 3565 3566 | set ::eskil(ignorenewline) 2 } elseif {$arg eq "-close"} { set ::eskil(autoclose) 1 } elseif {$arg eq "-conflict"} { set opts(mode) "conflict" } elseif {$arg eq "-print" || $arg eq "-printpdf"} { set nextArg printFile } elseif {$arg in {-printHeaderSize -printCharsPerLine -printPaper \ -printColorChange -printColorOld -printColorNew}} { set nextArg [string range $arg 1 end] } elseif {$arg eq "-server"} { if {$::tcl_platform(platform) eq "windows"} { catch { package require dde dde servername Eskil } } else { |
︙ | ︙ |