11

When I type "tehnically" using WinEdt it will transform into "thenically", and show in pdf that way. Why is this and how to erase it?

Zoxume
  • 1,093
nikola
  • 331
  • 5
    This is almost certainly a feature of your text editor and not TeX/LaTeX itself. What editor are you using? Does it have an autocorrect mode (which would appear to be misconfigured)? – Andrew Stacey May 02 '16 at 14:02
  • 1
    Which editor do you use? – Bernard May 02 '16 at 14:04
  • I have downloaded newest tex editor from internet, Winedt10.0 is written. I do not know how to configure tex editor. – nikola May 02 '16 at 14:05
  • Please also copy and paste part of your code into your question (or best a complete mini-example), given your previous posts today this could (unlikely but possible) be related to invisible control characters in your pasted text. – sheß May 02 '16 at 14:06
  • 3
    I don't use WinEdt, but when this happens to me, sometimes Ctrl-Z will undo the unwanted change. Assuming it is the "autocorrect" feature of WinEdt. This is not a bad question. – A Feldman May 02 '16 at 14:18
  • From an old 2007 post http://webcache.googleusercontent.com/search?q=cache:_pwV5V_tK-oJ:comments.gmane.org/gmane.editors.winedt/3359+&cd=1&hl=en&ct=clnk&gl=us You might have an "active string" defined as such under Options|Settings|Active Strings. Disable "on Type", and the function will stop working. I don't know whether this is germane to your 2016 problem, but give it a try. – A Feldman May 02 '16 at 14:30
  • 2
    Why do you want to spell "tehnically"? Perhaps you might try "technically"? – Benjamin McKay May 02 '16 at 14:58
  • 2
    Four own votes is bizarre. I agree with @AFeldman that this is a reasonable question. –  May 02 '16 at 15:02
  • Off topic...really? There are so many "need help with an editor" questions, why off topic this particular one. Not to mention lots of LyX related questions. – A Feldman May 02 '16 at 15:42
  • @BenjaminMcKay May be the OP shares my problem and in their native language there are words correctly spelled "teh*****"? – Jyrki Lahtonen Jan 10 '18 at 22:51
  • 1
    @JyrkiLahtonen Such an aggressive conduct about automatic spelling corrections would be a good reason for leaving the software aside. I might understand correcting teh<space> into the<space>, but “fixing” teh into the while typing is something I could not bear. – egreg Sep 22 '22 at 13:44

1 Answers1

11

This shouldn't happen. ‘teh’ is considered an active string because it often is a mistyping for ‘the’, and a macro defines auto-correction under special conditions. Check in your Options interface, on the right of the editor window, the contents of the file ActiveStrings.ini. It should contain exactly these lines:

STRING="teh"
  START_FILTER="~Alpha"
  END_FILTER="~Alpha"
  ENABLED=1
  MACRO="[BeginGroup;Backspace(2);Ins('he');EndGroup;]"

STRING="TEh"
  START_FILTER="~Alpha"
  END_FILTER="~Alpha"
  ENABLED=0
  MACRO="[BeginGroup;Backspace(2);Ins('he ');EndGroup;]"   

To modify the ActiveString.ini file (or any of the .ini files), open the Options interface in the left panel, select Active Strings to open it: enter image description here

There is a help icon, which directs you to the help for the current .ini file. Change the values to the correct ones, either by hand or by cut and paste. Once the file has been modified, validate the modifications by clicking on the leftmost icon (Load Current Script). If there's any syntax error, it will issue a warning. Otherwise, the modifications will be written to the script file that WinEdt reads on start, namely WinEdt.dnt (never write this one yourself!).

A Feldman
  • 3,930
Bernard
  • 271,350
  • I guess the OP should change the contents of the file ActiveStrings.ini to match what was posted in order to fix the problem. Does the OP need to do this in an external editor, or can it be done through the WinEdt dialogue? Looks like a really nice editor, although sadly I assume this does not run on Wine. – A Feldman May 02 '16 at 14:43
  • 1
    It has to be done from within WinEdt, then validated clicking on the Load Current Script icon. What I don't understand is why the O.P. has this behaviour. Filters are defined to prevent it. – Bernard May 02 '16 at 14:47
  • I would guess data corruption of some kind. I don't understand the down votes, perhaps they are RTFM related. But: http://meta.tex.stackexchange.com/a/6508/90087 And as you point out, this is a strange problem, not an ordinary thing one might easily look up. Maybe add to your answer the "hold my hand" type of details to fix the problem by modifying the string definitions. – A Feldman May 02 '16 at 14:50
  • The link to meta above is, among other things, about RTFM etiquette. – A Feldman May 02 '16 at 15:02
  • Perhaps because it about an editor, not about (La)TeX itself. But WinEdt is tightly linked to (La)TeX… – Bernard May 02 '16 at 15:11
  • Looks like an excellent answer to me. – A Feldman May 02 '16 at 15:11
  • Thanks @Bernard I had this same issue. Upon reading your explanation I just commented out those two sections from the ActiveStrings.ini file, and that fixed my problem. – Jyrki Lahtonen Jan 10 '18 at 22:40
  • 2
    @JyrkiLahtonen: Yes, I've just seen your post, and was going to answer when it was closed. I didn't even remember having answered for this problem! – Bernard Jan 10 '18 at 23:01