| Register | FAQ | Calendar | Search | Today's Posts | Mark Forums Read |
|
#11
| |||
| |||
| In article <c4c2dbe5-e7ed-484c-8393-84647dc24b6d@w39g2000prb.googlegroups.com>, JB <jbjunk1@gmail.com> wrote: |
|
#12
| |||
| |||
| In article <be687b5f-4808-40de-af6d-54a711e6e5a4@p31g2000prf.googlegroups.com>, JB <jbjunk1@gmail.com> wrote: |
|
#13
| |||
| |||
| At 2008-08-26 12:02PM, "JB" wrote: > # replace all "funny" chars with a dot > regsub -all {[^[:graph:][:blank:][\x00-\x08]|[\x0A-\x0C]|[\x0E- > \x1F]} $line "" line Yeah, I've never been very comfortable with some of those character classes ([:graph:],...) That regex can be simplified to: regsub -all {[\x00-\x08\x0A-\x1F]} $line "" line Make sure you update the comment, as you're not replacing with a dot anymore. > # not required, just house cleaning > regsub -all {[\[H\[J]} $line "" line This might be more efficient: set line [string map {{[H} "" {[J} ""} $line] -- Glenn Jackman Write a wise saying and your name will live forever. -- Anonymous |
![]() |
| Thread Tools | |
| Display Modes | |
In an effort to better serve ads to our visitors, cookies are used on objectmix.com. For more information, check out our Privacy Policy.