• Login
Community
  • Login

[Python] Replace spaces with tabs?

Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
3 Posts 2 Posters 457 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.
  • S
    Shohreh
    last edited by Mar 28, 2025, 12:10 PM

    Hello,

    Unless I missed it, I saw no item in the menus to convert Python code so that it uses TABs instead of spaces — I know, but I prefer TABs.

    Is there a plugin or some other solution?

    Thank you.

    ac980ed9-f016-4abb-8dd8-ef644aa52f67-image.png

    P 1 Reply Last reply Mar 28, 2025, 1:38 PM Reply Quote 0
    • P
      PeterJones @Shohreh
      last edited by Mar 28, 2025, 1:38 PM

      @Shohreh said in [Python] Replace spaces with tabs?:

      Unless I missed it, I saw no item in the menus

      You missed it.

      Edit > Blank Operations > Space to TAB (Leading) (see User Manual entry for details)

      93467433-46ad-458a-86c8-ffc0b2821496-image.png

      Also, if you want python to always use tabs for indentation, Settings > Preferences > Indentation: Python and set Indent = Tab character (see User Manual > Indentation settings for details):
      553797e5-84c7-4aa8-9974-c2ed9a28aa8e-image.png

      S 1 Reply Last reply Mar 28, 2025, 5:23 PM Reply Quote 5
      • S
        Shohreh @PeterJones
        last edited by Mar 28, 2025, 5:23 PM

        @PeterJones Thanks much for the infos.

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