15

Reasons to use Lucid over GTK Stability Examples from etc/PROBLEMS: ** When Emacs is compiled with Gtk+, closing a display kills Emacs. ... *** Emacs built with GTK+ toolkit produces corrupted display on HiDPI screen *** Emacs built with GTK+ toolkit can unexpectedly widen frames Recent example: Bug#25228 "custom-set-faces from init file ~/.emacs ...


8

I think the cause of the problem is visible-bell. Just put the following to your .emacs file: (setq ring-bell-function 'ignore) to get rid of both audible and visible bell


7

Maybe some clue in 'image.el'.. C-h v image-type-available-p image-type-available-p is an autoloaded compiled Lisp function in `image.el'. (image-type-available-p TYPE) Return non-nil if image type TYPE is available. Image types are symbols like `xbm' or `jpeg'.


6

Lucid Emacs uses the older lucid widget toolkit for XWindows. It looks older and greyer and I see no compelling reason to use it on a modern X desktop. Unless of course you have specific reasons to run it: run emacs in server mode on the background where the lucid version is reportedly more stable run on very stripped down X server configurations tldr; if ...


6

PATH vs exec-path The PATH environment variable lists directories for programs to find executable files (when executing a non-absolute filename). The exec-path Emacs variable lists directories for Emacs to find executable files (again, when executing a non-absolute filename). The value of exec-path takes its value from the environment variable PATH when ...


5

See kill-emacs-query-functions, which lets you query yourself to confirm quitting, to avoid accidental quitting. See desktop.el, which lets you save most of the state of your session when you quit, and restores it at the next session. See the Emacs manual, node Saving Emacs Sessions. See also savehist.el and bookmarks.


5

Found solution on this github: The window frame cannot be maximized 100% to suit the whole screen Seems like the problem was the selected font and setting the variable "frame-resize-pixelwise" to anything other than nul (default) solves the issue. I have added this line to my .emacs as suggested there: (setq frame-resize-pixelwise t) After restart emacs ...


5

You can use window-absolute-pixel-position: window-absolute-pixel-position is a compiled Lisp function in `window.el'. (window-absolute-pixel-position &optional POSITION WINDOW) Return display coordinates of POSITION in WINDOW. If the buffer position POSITION is visible in window WINDOW, return the display coordinates of the upper/left ...


5

When you run (server-start) it adds a function called server-kill-emacs-query-function (defined in server.el) to the kill-emacs-query-functions hook. One solution that might work for you (I've tested it and it works for me) is to modify your emacsclient line to emacsclient -c -a '' \ -e '(let (kill-emacs-query-functions confirm-kill-emacs kill-emacs-hook) (...


4

As noted in scaevola's answer, the problem is visible-bell. Completely turning off both audible and visible bell may seem a bit drastic, though. Here's a homebrew version of visible bell that just flashes the mode-line – but excluding some cases where the user deliberately caused the condition triggering the bell: (setq ring-bell-function (lambda () (...


4

I have created an image corresponding to the pepper.xpm in the below example. In emacs25.3 use 22x22 pixel image. I just copied one of the xpm image files in the /usr/share/emacs/25.3/etc/images (in Linux) folder, and resaved it in a different name (pepper.xpm) in the same folder. Add to your init.el | emacs.el: (add-hook 'after-init-hook (lambda ...


3

It looks like you're not using the frame argument which is passed to after-make-frame-functions. Try something like this: ;; Per-frame/terminal configuration. (defun my-frame-behaviours (&optional frame) "Make frame- and/or terminal-local changes." (with-selected-frame (or frame (selected-frame)) (when window-system ;; Fira code for GUI ...


3

To disable dialog windows set use-dialog-box to nil (setq use-dialog-box nil)


3

Since you're using my Emacs theme and could be using my emacs.d config, I suspect you have window-divider-mode enabled, which adds this border. You can either: Set the bottom border's width to 0: (setq window-divider-default-bottom-width 0) Turn off the bottom border: (setq window-divider-default-places 'right-only) or turn off window-divider-mode ...


2

Use the following script, compiled as an application (via ScriptEditor): tell application "Terminal" try -- Tests if Emacs running already; throws error otherwise do shell script "pgrep Emacs" -- Emacs is already running, is it an actual process? do shell script "/usr/local/bin/emacsclient -c -n &" on error ...


2

Assuming that you've configured with --with-ns (because you said it works if you open Emacs by clicking on the app icon), then you can start Emacs from the console in a couple of different ways. If you just want to start Emacs as an app then you can use the open command, so something like open nextstep/Emacs.app. The open command has a variety of arguments ...


2

I guess the encoding of your file is not properly detected. Typing C-x RET r windows-1252 RET should display your file properly as it forces Emacs to interpret the file as windows-1252 and not utf-8 (the default). If you want this file to always be opened with this encoding you can use a file-local variable.


2

I do not know for sure if the text becomes transparent, but this is what I use and I think works pretty well. However, if your font color is white, and you are reading a pdf with a white background color, even non-transparent text is going to be pretty hard to read. (setq transparency_level 0) (defun my:change_transparency () "Toggles transparency of ...


1

I've figured it out! It turns out there was a problem in my ~/.Xresources file preventing it from loading.


1

I believe that if system-configuration-features includes X11 then Emacs was compiled with X support. That value is set in configure by the HAVE_X11 variable being true (look for: emacs_config_features=), which in turn is based on window_system=x11 which you can trace back through a more complicated set of tests.


1

You can tell emacs the correct encoding adding a file local variable. Put -*- coding: windows-1250 -*- in the first line of the file or ;; Local Variables: ;; coding: windows-1250-dos ;; End: at the end. I used windows-1250 because the first line of the linked file is G bloiški, Ivan NOVAKOVIĆ with windows-1250 and G bloiški, Ivan ...


1

You can check display-graphic-p. See Display Feature Testing in the Emacs manual, there are a bunch of other display-*-p predicates for checking what display capabilities are available.


1

You may consider setting (setq confirm-kill-emacs 'yes-or-no-p) as described in https://www.gnu.org/software/emacs/manual/html_node/emacs/Exiting.html One convenient function to use as the value of confirm-kill-emacs is the function yes-or-no-p. The default value of confirm-kill-emacs is nil. And if you only want this to apply in the GUI version of ...


1

It looks like your font is fine, (some of) the special glyphs show up as expected. It's the colour that's broken. The following settings should sort out the colour: (add-to-list 'comint-output-filter-functions 'ansi-color-process-output) (ansi-color-for-comint-mode-on) With this config, the Hack font, and an appropriate definition of $PS1 I have the ...


1

For my settings I have the following: the shell script: #!/bin/sh /Applications/Emacs.app/Contents/MacOS/Emacs "$@" In my .zshrc: export EDITOR="/usr/local/bin/emacsclient" In my init.el: (global-git-commit-mode t) With these settings any git work from the command line moves to the GUI emacs.


1

Add a hook to the focus event. (add-hook 'focus-in-hook 'redraw-display). Thanks to Håkon Hægland for the Answer!


1

The problem is that the Ctl-Tab (and other escape sequences) aren't natively passed from the terminal to the application (emacs). Luckily, Xterm and emacs can be reconfigured to allow the passage of these sequences. Check out gilles's excellent overview here


1

The value inside '(tabbar-background-color "color-237") was invalid. Changed it to '(tabbar-background-color "#3A3A3A") - and it worked.


1

In emacs, a frame is always a separate graphical window (and as you know, in emacs the frame is divided into windows, making the terminology somewhat confusing). However, you can save window configurations to registers, and restore them later; see the "Configuration Registers" page of the emacs manual (M-: (info "(emacs)Configuration Registers")). There ...


1

Here's what I could come up with: (defun source-file-and-get-envs (filename) (let* ((cmd (concat ". " filename "; env")) (env-str (shell-command-to-string cmd)) (env-lines (split-string env-str "\n")) (envs (mapcar (lambda (s) (replace-regexp-in-string "=.*$" "" s)) env-lines))) (delete "" envs))) (exec-path-from-shell-copy-...


Only top voted, non community-wiki answers of a minimum length are eligible