Community
    • Login

    Pressing TAB key results in tabs in one document, but spaces in another

    Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
    tab indenttab alignmenttabs
    4 Posts 3 Posters 511 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • WisTexW
      WisTex
      last edited by

      I have this odd situation where one PHP document inserts a tab when I press the TAB key, but another PHP document, open at the same time, inserts spaces when I hit the TAB key.

      Changing the settings seems to have no effect. Closing and reopening the files seems to have no effect. Closing and reopening Notepad++ seems to have no effect.

      In sidebar.php I get spaces when I press TAB.
      In daily.php I get tabs when I press TAB.

      They are both PHP files, both have .php extension, and both have PHP set as the language in Notepad++.

      In Settings, under Preferences, under Language, it is set not to use spaces for tabs (which is what I want). Yet certain files use tabs and certain files use spaces when I press the TAB key on the keyboard.

      How do I get all files to behave the same?

      Michael VincentM 1 Reply Last reply Reply Quote 0
      • Michael VincentM
        Michael Vincent @WisTex
        last edited by

        @WisTex

        What is your debug info from the menu:

        ? > Debug Info ...

        It sounds like you may have a plugin installed that you forgot about? Namely:

        Auto Detect Indentation:

        Detects indention (tab or spaces) and auto adjust Tab key on-the-fly.
        Author: Mike Tzou (Chocobo1)
        Homepage: https://github.com/Chocobo1/nppAutoDetectIndent
        

        Cheers.

        WisTexW 1 Reply Last reply Reply Quote 3
        • WisTexW
          WisTex @Michael Vincent
          last edited by

          @Michael-Vincent Thank you so much. This was driving me crazy. Disabling it solved the problem. Much appreciated.

          1 Reply Last reply Reply Quote 2
          • Alan KilbornA
            Alan Kilborn
            last edited by

            This situation could also result from the use of the EditorConfig plugin, depending upon how it is configured with the .editorconfig files. Just sayin.

            1 Reply Last reply Reply Quote 2
            • First post
              Last post
            The Community of users of the Notepad++ text editor.
            Powered by NodeBB | Contributors