Comments (11)
I dug a little further and the relevant information is shown in proof-active-buffer-fake-minor-mode
in mode line. How can I make it displayed by default?
from doom-modeline.
According to the snippet below, the info is added to minor mode. So just enbale proof-active-buffer-fake-minor-mode
and (setq doom-modeline-minor-modes t)
.
from doom-modeline.
Yes, (setq doom-modeline-minor-modes t)
does the trick, but my modeline becomes super cluttered with 9(!) other minor modes shown and does not fit the frame. Is it possible to show just proof-active-buffer-fake-minor-mode
in my mode line, not others?
from doom-modeline.
If you don't like the default behavior, you can display it in global-mode-string
following by the FAQ 5.
e.g.
(add-to-list 'global-mode-string `(" " ,(coq-build-subgoals-string nbgoals nbunfocused)) " ")
PS: I didn't test it. It might be need some tweaks.
from doom-modeline.
Thanks. I tried a similar approach, which kind of worked:
(add-to-list 'global-mode-string `(" " ,(assoc 'proof-active-buffer-fake-minor-mode minor-mode-alist)) " ")
It shows me the number of goals in the mode line, but it is not updated when the number of goals changes. The Proof General code calls force-mode-line-update
when the number of goals changes but apparently, it does not affect doom-modeline.
from doom-modeline.
(add-to-list 'global-mode-string `(" " ,(assoc 'proof-active-buffer-fake-minor-mode minor-mode-alist)) " ")
This doesn't work while the number changes, since it won't be evaluated. You should use function or eval to force to update.
from doom-modeline.
I don't know how to do that. This is a static list. How can I add a function which evaluates later into it?
I want to point out that the Proof General code forces updates of proof-active-buffer-fake-minor-mode
string when the number of goals changes. It just did not get propagated to doom-modeline.
from doom-modeline.
Try this
(add-to-list 'global-mode-string '(" " (:eval (coq-build-subgoals-string nbgoals nbunfocused))) " ")
from doom-modeline.
There are no nbgoals
and nbunfocused
variables. They are local variables in coq-update-minor-mode-alist
function, not exposed outside.
from doom-modeline.
(add-to-list 'global-mode-string '(" " (:eval (assq 'proof-active-buffer-fake-minor-mode minor-mode-alist))) " ")
from doom-modeline.
It worked! Thanks! In case someone else will be looking for the solution: I've added it to the hook for coq-mode in proof general use-package definition:
(use-package proof-general
:ensure t
:after doom-modeline
:mode ("\\.v\\'" . coq-mode)
:custom
(coq-smie-user-tokens '(("≈" . "=") ("≡" . "=")))
(proof-splash-enable nil)
(coq-prog-name "coqtop")
(coq-compile-before-require nil)
:hook
(coq-mode . (lambda ()
(ws-butler-mode)
(helm-mode)
(add-to-list 'global-mode-string '(" " (:eval (assq 'proof-active-buffer-fake-minor-mode minor-mode-alist))) " ")
)))
from doom-modeline.
Related Issues (20)
- [Feature Request] Add support for `jupyter-repl-interaction-mode-line`
- [Bug] Emacs 29.1 - Warning (comp): doom-modeline-core.el:1098:37: Warning: reference to free variable ‘mode-line-right-align-edge’ HOT 4
- [Feature Request] Feed path through `abbreviate-file-name` HOT 2
- [Bug] buffer-state-icon display error HOT 1
- [Bug] need update for latest jsonrpc accessor change: `jsonrpc--request-continuations` HOT 9
- [Feature Request] Support for Flycheck-status-emoji HOT 4
- Error using with latest eglot / jsonrpc packages HOT 4
- Can the 'which-function' be disabled? HOT 2
- [Bug] buffer-position formatting won't respect flags in format specifier for column HOT 4
- [Bug] Lightbulb symbol 01F4A1 not displaying in mode line HOT 3
- [Feature Request] display-all-git-branches HOT 2
- [Bug] Icons on modeline lack sufficient padding HOT 14
- [Bug] modeline fragments do not get updated correctly when a command that changes the current-buffer is running HOT 3
- [Bug] HOT 3
- [Bug] Setting a left window margin clips the modeline on the right HOT 4
- [Bug] Compiler warnings after 311a0c5 HOT 1
- Fix the few faces that don't inherit from doom-modeline HOT 1
- Symbol’s function definition is void: doom-modeline-check-icon HOT 4
- [Bug] Typo in commit 3f1d33a
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from doom-modeline.