Author Topic: Tab key sometimes inserting spaces instead of tabs  (Read 185 times)

Eric777

  • Junior Community Member
  • Posts: 7
  • Hero Points: 0
Tab key sometimes inserting spaces instead of tabs
« on: August 18, 2020, 05:21:19 pm »
I am on Windows 10 with SlickEdit Pro 2019 (v24.0.2.0 64-bit)

I prefer indenting with tabs.  I have been pouring over the tabs/spaces settings in SlickEdit, but I'm still getting at some instances where I am getting spaces when it seems I should get tabs.  I have indent style set to 'auto' (not syntax indent), I have adaptive formatting off, I have 'indent with tabs' checked, and I have tab size set to 4. (I will also attach my user.cfg.xml).

void foo()
{
   bar();
}

When I first write that code, the 'b' in bar() is on column 5.  Hexing out the file shows that line begins with 1 tab.  If I place the cursor right on the 'b' in bar() and press backspace, bar() moves to column 1 as expected.  Then if I press tab to re-indent, bar() moves 2 spaces out to column 3 (?).  Saving out that file confirms that line now begins with 2 spaces instead of 1 tab.

If I instead write the code like this:

void foo()
{
   int x;
}

I do not see the weird spaces behavior there.  I always get a tab as expected when re-indenting the line when it contains 'int x;'.

I use a proportional font (Verdana at size 10).  I've discovered that I only see the strange behavior with bar() when using Verdana, I do not see it when using a fixed font.  I don't see the strange behavior with 'int x;' regardless of which font I'm using.

I don't know if this is a bug, or some setting I'm missing with regards to indent/align (probably the latter).  Does anyone know what might be happening here?

Clark

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 5549
  • Hero Points: 449
Re: Tab key sometimes inserting spaces instead of tabs
« Reply #1 on: August 18, 2020, 06:39:13 pm »
Added a hot fix for this

Eric777

  • Junior Community Member
  • Posts: 7
  • Hero Points: 0
Re: Tab key sometimes inserting spaces instead of tabs
« Reply #2 on: August 18, 2020, 07:23:53 pm »
Wow!  My head is spinning.  Thank you!  I'm a trial user on my 4th day, so I had no idea how fast you guys could be.

I downloaded the hotfix from here: https://customer.slickedit.com/index.php?option=com_content&view=article&id=316

It's dated yesterday though, do these get pushed out once a day or so?

Clark

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 5549
  • Hero Points: 449
Re: Tab key sometimes inserting spaces instead of tabs
« Reply #3 on: August 18, 2020, 08:09:50 pm »
We are working on building a new hot fix now. Should be available by some time tomorrow. It will need to be greater than 16 which is the current hot fix for v24.0.2.

There is no schedule for hot fixes. We add them on an as needed basis.