|
Posted by Bryan Oakley on 04/21/06 20:22
comp.lang.tcl wrote:
> Last I checked [string totitle] doesn't capitalize hyphenated names,
> Scots/Irish/Dutch names, etc. I wrote it back in 2000, when I only had
> about a year's knowledge of TCL at the time, I'm sure it needs a bit of
> fine-tuning, but it does the job it's supposed to do.
>
> Phil
It's pretty fragile though. As I pointed out in another message in this
thread, it can get into an infinite loop if a word begins or ends with
"-" or "_". It also will yield unexpected results for other types of
input as well. So, it really only works for a small set of well behaved
inputs.
We can help you with those problems if you like.
Not sure what to do about the OP, other than to suggest perhaps writing
their own PROPER_CASE proc or help to debug this one. There appears to
be no good way to solve his/her problem other than to fix PROPER_CASE.
--
Bryan Oakley
http://www.tclscripting.com
Navigation:
[Reply to this message]
|