I am trying to show line numbers in an NSTexView. I was using the solution from http://www.noodlesoft.com/blog/2008/10/05/displaying-line-numbers-with-nstextview/ but it is no more working with Lion.
Do you know an alternative solution?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
I think you probably need an updated version of the files for 64bit (Lion).
I forked the NoodleKit project on GitHub and made some changes that I found on the web. I made some small tweaks, but the changes here mostly came from others on the Internet and the original repo. The owner of the repo has not updated the NoodleLineNumberview in two years, but I may send a pull request so he will add it to his repo. These classes are working in my Lion projects, so they should work for you.
Update your project with these new files and then try to compile:
If you are using the MarkerLineNumberView that came with an old version of the project, then that will not work here. Just replace those objects with NoodleLineNumberView.