[ale] [OT] Making Emacs transparent in Cywgin

Jonathan Meek jonathan.l.meek at gmail.com
Thu Oct 31 14:32:36 EDT 2013


I know recently there's been a lot of back and forth on the list of what
counts as "on-topic" and "off-topic" so I had a lot of fear posting the
email. Also, I wasn't really clear in the email on what the goal was. The
goal was to allow Emacs to have a transparent background so one could lay
their editor over an active window. For example, I am currently working in
design for project at work and I take my notes using a GUI version of Emacs
that I installed via Cywgin. The instructions I got over a few different
resources and figured it would be helpful to send out to everyone in a step
by step process. I probably fubared some of the terminology in the process
and hit the send button a bit fast.

Jerald, hopefully that makes what I was aiming to do a bit clear and Mike,
my apologies because I completely missed the wink face somehow. Not sure
how I pulled that stunt off but it happened. So sorry for the crossed wires
on my part. I violated my cardinal rule of letting messages brew over 30
minutes before sending.


On Thu, Oct 31, 2013 at 2:27 PM, Jim Kinney <jim.kinney at gmail.com> wrote:

> YOU HAVE USED YOUR ENTIRE ALLOTMENT OF PARENTHESES FOR NOVEMBER 2013
> THROUGH MARCH 2015
>
> THIS WILL BE YOUR FINAL WARNING.
>
>
> cygwin kept me sane while doing HPUX support on win2k systems at HP.  It
> also meant I had more capabilities than everyone else so I ran virtual
> screens (in 2001 windows) so I could track more running things than the
> rest of the team :-)
>
> Nice hack!
>
>
> On Thu, Oct 31, 2013 at 10:21 AM, Jonathan Meek <jonathan.l.meek at gmail.com
> > wrote:
>
>> Hey guys,
>>
>> Came across a way to make Emacs transparent in Cywgin after a bit of
>> research and wanted to share.
>>
>> 1) start up Emacs
>> 2) Add the following code to the buffer:
>>
>>          (defun djcb-opacity-modify (&optional dec)
>>   "modify the transparency of the emacs frame; if DEC is t,
>>     decrease the transparency, otherwise increase it in 10%-steps"
>>   (let* ((alpha-or-nil (frame-parameter nil 'alpha)) ; nil before setting
>>           (oldalpha (if alpha-or-nil alpha-or-nil 100))
>>           (newalpha (if dec (- oldalpha 10) (+ oldalpha 10))))
>>     (when (and (>= newalpha frame-alpha-lower-limit) (<= newalpha 100))
>>       (modify-frame-parameters nil (list (cons 'alpha newalpha))))))
>>
>>  ;; C-8 will increase opacity (== decrease transparency)
>>  ;; C-9 will decrease opacity (== increase transparency
>>  ;; C-0 will returns the state to normal
>> (global-set-key (kbd "C-8") '(lambda()(interactive)(djcb-opacity-modify)))
>> (global-set-key (kbd "C-9") '(lambda()(interactive)(djcb-opacity-modify
>> t)))
>> (global-set-key (kbd "C-0") '(lambda()(interactive)
>>                                (modify-frame-parameters nil `((alpha .
>> 100)))))
>>
>> 3) save the file (C-x C-s) at ~/emacs.d/init.el
>> 4) restart Emacs
>>
>> Note: this sets that C-8 decrease transparency, C-9 to increase
>> transparency and C-0 to set to normal
>>
>> Resources to make this guide:
>> http://emacs-fu.blogspot.com/2009/02/transparent-emacs.html
>> http://www.cs.colostate.edu/helpdocs/emacs.html
>> http://www.emacswiki.org/emacs/InitFile
>>
>> Regards,
>>
>> Jonathan
>>
>> _______________________________________________
>> Ale mailing list
>> Ale at ale.org
>> http://mail.ale.org/mailman/listinfo/ale
>> See JOBS, ANNOUNCE and SCHOOLS lists at
>> http://mail.ale.org/mailman/listinfo
>>
>>
>
>
> --
> --
> James P. Kinney III
> *
> *Every time you stop a school, you will have to build a jail. What you
> gain at one end you lose at the other. It's like feeding a dog on his own
> tail. It won't fatten the dog.
> - Speech 11/23/1900 Mark Twain
> *
> http://heretothereideas.blogspot.com/
> *
>
> _______________________________________________
> Ale mailing list
> Ale at ale.org
> http://mail.ale.org/mailman/listinfo/ale
> See JOBS, ANNOUNCE and SCHOOLS lists at
> http://mail.ale.org/mailman/listinfo
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.ale.org/pipermail/ale/attachments/20131031/e9ec25d3/attachment.html>


More information about the Ale mailing list