Re: [code] [textadept] goto_line and retina displays

From: Mitchell <m.att.foicica.com>
Date: Mon, 1 Apr 2013 15:19:13 -0400 (Eastern Daylight Time)

Hi John,

On Mon, 1 Apr 2013, John Benediktsson wrote:

> Hi,
>
> We recently received a contribution[1] to the Factor programming language
> that provided integration with Textadept (to be able to easily edit a
> function by loading its definition into the Textadept editor).
>
> It required manually defining a "jump-to-line" command-line argument to the
> users init.lua file (to load the file containing the definition and then
> configure the editor to position the cursor on the first line of its
> definition):
>
> function my_goto_line(line)
> _G.buffer:goto_line(line - 1)
> end
> args.register('-J', '--JUMP', 1, my_goto_line, 'Jump to line')
>
> It would be nice if this feature (with similar or different command-line
> arguments) would be added to the base editor.

I'm not familiar with Factor, but briefly looking at the commit, I think I
see an arg string being constructed:

   textadept-path , "-f" , , "-J" , number>string ,

This would appear to produce something like:

   /path/to/ta -f [file] -J 10

You should be able to craft a similar arg string like:

   /path/to/ta -f [file] -e "goto_line(10 - 1)"

to bypass the commit's necessary args.register() in ~/.textadept/init.lua.
This would work out of the box without any modifications.

> Also, Textadept doesn't seem to support high-resolution "retina" displays
> on OS X and looks a bit blurry on the latest Macbook Pros. I tried the
> recently released 6.5 also and it is the same - wondering if you have plans
> to address this.

It seems that if you edit your Textadept.app/Contents/Info.plist to add[1]

   <key>NSHighResolutionCapable</key>
   <true/>

then Retina support is enabled. Could somebody verify that for me? If so
I'll add it to the build.

Cheers,
Mitchell

[1]: https://mail.gnome.org/archives/gtk-list/2012-August/msg00043.html

-- 
You are subscribed to code.att.foicica.com.
To change subscription settings, send an e-mail to code+help.att.foicica.com.
To unsubscribe, send an e-mail to code+unsubscribe.att.foicica.com.
Received on Mon 01 Apr 2013 - 15:19:13 EDT

This archive was generated by hypermail 2.2.0 : Tue 02 Apr 2013 - 06:30:50 EDT