extra => custom
This commit is contained in:
parent
ba011b6ffe
commit
4057c56e4c
7 changed files with 120 additions and 147 deletions
55
modules/custom-demo.el
Normal file
55
modules/custom-demo.el
Normal file
|
@ -0,0 +1,55 @@
|
|||
;;; custom-demo.el --- -*- no-byte-compile: t; -*-
|
||||
|
||||
(defvar powerline-height)
|
||||
|
||||
;; This library offers:
|
||||
;; + impatient-mode: for broadcasting my emacs session
|
||||
;; + big-mode: for enlarged text while screencasting
|
||||
;; + TODO integration with reveal.js for presentations
|
||||
;; + TODO peer programming collab
|
||||
|
||||
;; Big-mode settings
|
||||
(defconst big-mode-font (font-spec :family "Inconsolata" :size 16))
|
||||
(defconst big-mode-line-spacing 0)
|
||||
(defconst big-mode-modeline-height 35)
|
||||
|
||||
;;
|
||||
(use-package impatient-mode
|
||||
:commands impatient-mode
|
||||
:config (httpd-start))
|
||||
|
||||
(defvar big-mode--old-line-spacing line-spacing)
|
||||
(defvar big-mode--old-modeline-height powerline-height)
|
||||
(define-minor-mode big-mode
|
||||
:init-value nil
|
||||
:lighter " BIG"
|
||||
:global t
|
||||
(when big-mode-font
|
||||
(doom/load-font (if big-mode big-mode-font doom-default-font)))
|
||||
(if big-mode
|
||||
(setq-default
|
||||
powerline-height big-mode-modeline-height
|
||||
line-spacing big-mode-line-spacing)
|
||||
(setq-default
|
||||
powerline-height big-mode--old-modeline-height
|
||||
line-spacing big-mode--old-line-spacing)))
|
||||
|
||||
(evil-define-command doom:big (&optional size)
|
||||
"Use to enable large text mode."
|
||||
(interactive "<a>")
|
||||
(if size
|
||||
(let ((big-mode-font big-mode-font))
|
||||
(big-mode -1)
|
||||
(font-put big-mode-font :size (string-to-int size))
|
||||
(big-mode +1))
|
||||
(big-mode (if big-mode -1 +1))))
|
||||
|
||||
(defun doom/resize-for-stream ()
|
||||
"Resize the frame pixelwise, so that it fits directly into my livecoding.tv
|
||||
streaming layout."
|
||||
(interactive)
|
||||
(set-frame-width (selected-frame) 1325 nil t)
|
||||
(set-frame-height (selected-frame) 1080 nil t))
|
||||
|
||||
(provide 'custom-demo)
|
||||
;;; custom-demo.el ends here
|
Loading…
Add table
Add a link
Reference in a new issue