I want to use emmet-mode in emacs - emacs

I want to use emmet-mode in emacs with .jade files but emmet-mode don't work. It expand html but not jade sintaxis.
Thank you.

As mentioned in the Optional Settings section of the README.md, you can enable emmet-mode based on major mode like so:
(add-hook 'jade-mode-hook #'emmet-mode)
emmet-mode should now be enabled with jade-mode, and C-j should be bound to emmet-expand-line.

Related

.scss file with emacs web-mode & colorization

I'm using emacs with web modes and other stuff.
I'm updating my .emacs because I'm working with new tools. One of them is Sass. So, I wanna work with my *.scss files without problem and in fact it works cool. But not perfect. Why?
My emacs has:
(setq web-mode-enable-css-colorization t)
And in my css I can see the colors. But in my scss I can't.
How can I activate css-colorization to scss files?
Maybe this could help.
There is a Major mode for editing SCSS files in Emacs:
https://www.emacswiki.org/emacs/ScssMode
I finally did it.
But it was with a work around. So,
I installed the rainbow-mode from Elpa.
Plus, in my .emacs I added:
(add-hook 'web-mode-hook 'rainbow-mode)
Thanks!

How to make minimap run in specified modes?

I installed GNU minimap (version 1.2).
When I open certain type of files , e.g. .py, .c, the minimap comes out as expected.
However, when I open .html file, the minimap is not started.
Is there a way to add additional modes where the minimap automatically shown?
I tried to add hooks to .emacs file but it just starts minimap-mode, but no displaying any minimap.
(add-hook 'html-mode-hook 'minimap-mode)
By default, minimap-mode only works for modes that derive from prog-mode (most modern modes for programming, including python-mode and c-mode). Modify minimap-major-modes if you want to activate it for others, e.g.
(setq minimap-major-modes '(prog-mode html-mode))
or
(add-to-list 'minimap-major-modes 'html-mode)

How do I activate "lisp mode" for cljs files in emacs?

Currently emacs isn't turning on paredit and isn't using any syntax highlighting when I edit .cljs files. It does when I edit .clj files and I want it to treat .cljs similar.
What do I have to do?
If you already have everything working for clojure you can just turn clojure-mode on for the current buffer using
M-x clojure-mode
If you want it turned on automatically you need to add an entry to the Auto Mode AList. In my case, adding the following to init.el did the trick:
(add-to-list 'auto-mode-alist '("\.cljs$" . clojure-mode))
After that you need to reload your init.el (M-x load-file) and re-open the file.

LaTeX-mode hooks not loading in emacs (24.3.50) with AUCTeX (11.87.3)

Since I updated to emacs 24 I cannot get AUCTeX to load the LaTeX-mode hooks, e.g.
(add-hook 'LaTeX-mode-hook 'visual-line-mode)
despite:
C-h m tells me that my major mode is Major mode in AUCTeX for editing LaTeX files.
the AUCTeX mode help states:
Entering LaTeX mode calls the value of `text-mode-hook',
then the value of `TeX-mode-hook', and then the value
of `LaTeX-mode-hook'.
(Indeed, the text-mode hooks are not loaded either.)
Hooks for other modes (e.g. for Markdown or Python) do work.
And, of course, I have tested that manual activation, e.g. M-x visual-line-mode, does work.
Thanks!
This is strange C-hm gives me
Entering Latex mode runs the hook text-mode-hook', then
tex-mode-hook', and finally `latex-mode-hook'.
Notice that it is latex-mode-hook and not LaTeX-mode-hook.
EDIT - I do not have auctex installed maybe that explains why the help messages are different for us, ignore the part above. You can try the below as an alternative
(add-hook 'latex-mode-hook 'visual-line-mode)
As is noted in the comments in the other answer, this issue is caused by AucTeX being unable to create XPM images. This occurs when when Emacs is not compiled with the libxpm library, which might be the case when you run Emacs primarily inside your favorite terminal emulator.
Anyways, you can still correct this issue without recompiling Emacs. In fact, the images are only used for the AucTeX toolbar. Thus, disabling it will effectively remove the problem altogether. You can do this by adding:
(unless (image-type-available-p 'xpm)
(setq LaTeX-enable-toolbar nil))
To your .emacs (or .emacs.d/init.el) file.
This snippet simply checks if XPM images are available in the Emacs installation and if not, it disables the toolbar.

docview in emacs: refreshing dvi content automatically

Is there a way Emacs can automatically refresh the buffer showing the dvi right after my LaTeX compilation?
Thank you.
The global auto revert is not always desirable, in fact I only use it for for the DocView to see the new output of pdflatex.
The following will allow auto revert for the DocView major mode
(add-hook 'doc-view-mode-hook 'auto-revert-mode)
Use interactive function:
auto-revert-mode
to enable reloading when the file changes.