title: Regex expression to match tab
body: <p>I need a regular expression that matches tab symbol by the following rules:</p>
  <pre><code>&quot;—&gt;text&quot;       does not match
  &quot;1.—&gt;text&quot;     does not match
  &quot;1—&gt;text&quot;      does not match
  &quot;A.—&gt;text&quot;     does not match
  &quot;text—&gt;text&quot;   match
  </code></pre>
  <p>That is, it shouldn't match tabs that are at the beginning of the text, after a listed item mark [A-Z] or [0-9]. Here is my expression:</p>
  <pre><code>(?&lt;!^((?:\d+|[A-Z])(?:\.)?))\t(?!\1)
  </code></pre>
  <p><a href="https://regex101.com/r/zgJAG9/1/" rel="nofollow noreferrer">https://regex101.com/r/zgJAG9/1</a></p>
  <p>It does not work for all cases:</p>
  <p><a href="https://i.stack.imgur.com/PMlIz.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/PMlIz.png" alt="enter image description here" /></a></p>
  <p>How to fix it?</p>