Note that there are some explanatory texts on larger screens.

plurals
  1. POHow to set a key binding to make Emacs as transparent/opaque as I want?
    primarykey
    data
    text
    <p>I want to have a command in Emacs to make it as opaque/transparent as I want (refer to the fabulous <a href="https://stackoverflow.com/questions/2010158/setting-an-emacs-background-image">question</a> that pointed out that transparency is possible in Emacs, and the <a href="http://www.emacswiki.org/emacs/TransparentEmacs" rel="nofollow noreferrer">EmacsWiki</a> page linked there which has the code I am using below).</p> <p>The EmacsWiki code sets "C-c t" to toggle the previously set transparency on and off:</p> <pre><code>;;(set-frame-parameter (selected-frame) 'alpha '(&lt;active&gt; [&lt;inactive&gt;])) (set-frame-parameter (selected-frame) 'alpha '(85 50)) (add-to-list 'default-frame-alist '(alpha 85 50)) enter code here(eval-when-compile (require 'cl)) (defun toggle-transparency () (interactive) (if (/= (cadr (find 'alpha (frame-parameters nil) :key #'car)) 100) (set-frame-parameter nil 'alpha '(100 100)) (set-frame-parameter nil 'alpha '(85 60)))) (global-set-key (kbd "C-c t") 'toggle-transparency) </code></pre> <p>What I would like to do is to be able to choose the % transparency when I am in Emacs. </p> <p>If possible, I would like a command where I type for example "C-c t N" (where N is the % opaqueness) for the active frame, and then "M-c t N" for the inactive window. </p> <p>If that can't be done like that, then maybe a command where if I type "C-c t" it asks me for the number which gives the opaqueness of the active window (and the same for the inactive window using "M-c t").</p> <p>Thanks in advance for your time :)</p> <p><strong>Below are just some comments that are not important to answer the question if you are not interested:</strong></p> <p>I really want this because when I told my supervisor I was learning Emacs he said TexShop is much better and that I am using software from the 80's. I told him about the wonders of Emacs and he said TexShop has all of it and more. I matched everything he showed me except for the transparency (though he couldn't match the preview inside Emacs from preview-latex). I found the transparency thing by chance, and now I want to show him Emacs rules!</p> <p>I imagine this will be a piece of cake for some of you, and even though I could get it done if I spent enough time trying to learn lisp or reading around, I am not a programmer and I have only been using Emacs and a mac for a week. I am lost already as it is! So thanks in advance for your time and help - I will learn lisp eventually!</p> <p><strong>Edit:</strong> My supervisor uses TextMate, not TeXShop. Does it make more sense now?</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload