[code] look and feel and xsel with textadept.

From: Joseph McDonald <joe.att.vpop.net>
Date: Sat, 04 Apr 2015 01:18:45 -0700

Hi, loving textadept and tweaking it, have a few questions:

1) Look and feel:
   the code folding markers are overlapping with my text
   by a pixel or so in curses textadept. I'd like some
   more space to the right of them So I made it 3 for the
   console in my init.lua:

   buffer.margin_width_n[2] = not CURSES and 24 or 3

   but it doesn't take effect unless I do a "reset()" while
   the buffer is active, and then sometimes if I switch away
   from that buffer and back to it, it loses the margin again.

   -- how to get cursor to blink in console?
   buffer.caret_style = buffer.CARETSTYLE_BLOCK
   buffer.caret_period = 300 -- doesn't work in console

   -- how to change cursor color in console? (to orange for instance?)
   -- how to highlite current line in console?

2) I'd like textadept to work with my system clipboard, so
   that the textadept clipboard can be pasted to any app and
   vice versa. I think "xsel" is the way to go for that:

https://hugoheden.wordpress.com/2009/03/08/copypaste-with-emacs-in-terminal/

   So I have this function:
     xsel_outgoing = function()
       proc = spawn('xsel --clipboard --input', nil, nil)
       proc:write(ui.clipboard_text)
       proc:close()
     end

   and I hooked it up to a few keystrokes that I use for
   cutting and copying text, but how do I make it more universal?
   That is, anytime something goes onto ui.clipboard text
   the xsel function is called? BTW, to let xsel work on
   a remote host with textadept-curses, ssh in with: ssh -X.

   for yanking text in from xsel, I'm not sure how to get
   the output of a shell command, what to call?:

   xsel_in = function()
    -- XXX how to call shell and get output?
    data = shell('xsel --clipboard --output')
   end

thanks,
-joe

-- 
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 Sat 04 Apr 2015 - 04:18:45 EDT

This archive was generated by hypermail 2.2.0 : Sat 04 Apr 2015 - 06:47:13 EDT