I'm trying to implement a multi column layout for a hex editor using TextKit2. I'm using the sample App named "LayoutTextWithTextKit2" as my starting point, but I'm struggling to understand what the best approach could be to implement it.
My doubts are:
- Is it a good idea to use a text element for a single line in a single column? I'm basing my text element on
NSTextParagraph
. - Following my previous question, is there any way to layout these text elements horizontally in a single line, instead of having the layout engine automatically lay them out in a vertical stack?
- Where is the correct location where I can override the positioning for each text element manually if I wanted to not base my elements in
NSTextParagraph
? Would this be a good idea?
I apologize for the many questions, but my basic problem is that it's not clear to me if I'm missing something that's obvious, and there's a simple way to address my troubles. Any guidance towards that goal, even beyond my questions above, will be appreciated.
I'm attaching an image showing two fragments that I'd like to be laid out horizontally in the same line, for reference.