1

I have a wxStyledTextCtrl and I want to find the column number of a given position in the document. Basically I want a function like GetColumn but I don't want tabs to be expanded.

Does such a function exist?

Stefano Mtangoo
  • 6,017
  • 6
  • 47
  • 93
Nathan Osman
  • 71,149
  • 71
  • 256
  • 361

1 Answers1

0

You can use PositionToXY() method (inherited from the base class) to get this, at least with 2.9.4 it should give you what you need. If you use 2.8 and it doesn't work for you, you should do line = LineFromPosition(pos) and then use pos - PositionFromLine(line) as the index in this line.

VZ.
  • 21,740
  • 3
  • 39
  • 42