Giter VIP home page Giter VIP logo

phd-modeline's Introduction

phd-modeline.el

This is my customization of the Emacs mode-line.

It provides a minor-mode for toggling the phd-modeline which includes more human-readable features (opposed to the default “encodings”).

In particular it features:

  • indicator bar (see screenshot; rectangular, triangular, arrow-shape, etc.)
  • buffer state icons (read-only & modified)
  • version control identification and iconification
  • unread mail indicator (provided you use mu4e)
  • major-mode iconification and descriptione

For the iconification, it uses the all-the-icons package which is the only requirement.

Installation

Download this git repository, e.g. to your home directory. In your init.el (or equivalent Emacs startup-file), use

(add-to-list 'load-path "~/phd-modeline/")
(require 'phd-modeline)
(phd-modeline-mode 1)
(global-set-key (kbd "C-x |") 'phd-modeline-mode)

or in case you’re using use-package

(use-package phd-modeline
  :ensure nil
  :load-path "~/phd-modeline/"
  :after (all-the-icons mu4e)
  :hook (after-init . phd-modeline-mode)
  :bind (("C-x |" . phd-modeline-mode)))

Configuration examples

The default phd-modeline format is still quite conservative and minimalistic. However, many features can be included in your configuration and customization.

Just like for mode-line, customizations can be applied by setting the phd-modeline-format (mode-line-format in case of mode-line):

(setq phd-modeline-format
      (list
       '(:eval (phd-modeline-bar))
       ;; analogously list all components here
       ))

For instance, my personal configuration looks like

(use-package phd-modeline
  :ensure nil
  :load-path "~/local/phd-modeline/"
  :after all-the-icons
  :hook (after-init . phd-modeline-mode)
  :bind (("C-x |" . phd-modeline-mode))
  :config

  (require 'phd-mu4e-setup)  ;; this is my personal mu4e setup
  (setq phd-modeline-mu4e-unread-query phd-mu4e-inbox-query)
  (phd-modeline-mail-mode t)

  (phd-modeline-column-mode t)
  (setq phd-modeline-format
        (list
         '(:eval (phd-modeline-bar))
         '(:eval (phd-modeline-whitespace))
         '(:eval (phd-modeline-buffer-lock-icon))
         '(:eval (phd-modeline-buffer-name))
         '(:eval (phd-modeline-buffer-modified-icon))
         '(:eval (phd-modeline-whitespace))
         '(:eval (phd-modeline-buffer-position))
         '(:eval (phd-modeline-media-info))
         '(:eval (phd-modeline-whitespace))
         '(:eval (phd-modeline-flycheck-status))
         '(:eval (phd-modeline-whitespace 4))
         '(:eval (phd-modeline-vc-icon 1 1 1))
         '(:eval (phd-modeline-vc-status))
         '(:eval (phd-modeline-whitespace 4))
         '(:eval (phd-modeline-mail-icon))
         '(:eval (phd-modeline-mail-status))
         '(:eval (phd-modeline-whitespace))
         '(:eval (phd-modeline-space-between 4))
         '(:eval (phd-modeline-mode-icon))
         '(:eval (phd-modeline-whitespace))
         '(:eval (phd-modeline-major-mode))
         '(:eval (phd-modeline-whitespace)))))

./imgs/screenshot_example.png

phd-modeline's People

Contributors

phdenzel avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

Forkers

thechampagne

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.