Tcl Source Code

Check-in [21d7b4b106]
Login

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

Overview
Comment:And add the listing of supported options.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | tip-404
Files: files | file ages | folders
SHA1: 21d7b4b1060746d5a2a4cdb90633723f8050014b
User & Date: dkf 2012-08-28 14:28:01
Context
2012-08-28
14:28
And add the listing of supported options. Closed-Leaf check-in: 21d7b4b106 user: dkf tags: tip-404
14:15
Added mcconfig -mcfilelocale, as TIP-specified. check-in: 674aa977f0 user: dkf tags: tip-404
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to library/msgcat/msgcat.tcl.

456
457
458
459
460
461
462
463
464



465
466
467
468






469
470
471
472
473
474
475
476
	if {$len>$max} {
	    set max $len
	}
    }
    return $max
}

proc msgcat::mcconfig {option {value "\u0000\u0000\u0000"}} {
    # Handle sentinel



    if {$value eq "\u0000\u0000\u0000"} {
	unset value
    }







    switch $option {
	-mcfilelocale {
	    variable FileLocale
	    if {[info exists value]} {
		set FileLocale $value
	    }
	    return $FileLocale
	}







|
|
>
>
>




>
>
>
>
>
>
|







456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
	if {$len>$max} {
	    set max $len
	}
    }
    return $max
}

proc msgcat::mcconfig {{option "\u0000\u0000\u0000"} {value "\u0000\u0000\u0000"}} {
    # Handle sentinels
    if {$option eq "\u0000\u0000\u0000"} {
	unset option
    }
    if {$value eq "\u0000\u0000\u0000"} {
	unset value
    }

    set optionNames {-mcfilelocale}

    if {![info exists option]} {
	return $optionNames
    }
    # TODO: consider using [tcl::prefix] to expand $option
    switch -- $option {
	-mcfilelocale {
	    variable FileLocale
	    if {[info exists value]} {
		set FileLocale $value
	    }
	    return $FileLocale
	}