aboutsummaryrefslogtreecommitdiff
path: root/Emacs/.config/emacs/config.org
diff options
context:
space:
mode:
Diffstat (limited to 'Emacs/.config/emacs/config.org')
-rw-r--r--Emacs/.config/emacs/config.org168
1 files changed, 81 insertions, 87 deletions
diff --git a/Emacs/.config/emacs/config.org b/Emacs/.config/emacs/config.org
index 2a0367b..758739e 100644
--- a/Emacs/.config/emacs/config.org
+++ b/Emacs/.config/emacs/config.org
@@ -2408,32 +2408,67 @@ Some bindings for org mode.
(local-leader
:keymaps 'org-mode-map
"t" #'org-todo
+ "i" #'org-insert-structure-template
"p" #'org-latex-preview
"s" #'org-property-action
"e" #'org-export-dispatch
- "o" #'org-edit-special)
- )
+ "o" #'org-edit-special))
#+end_src
-*** Org message
-Org message allows for the use of org mode when composing mails,
-generating HTML multipart emails. This integrates the WYSIWYG
-experience with mail in Emacs while also providing powerful text
-features with basically no learning curve (as long as you've already
-learnt the basics of org).
-
+*** Org agenda
+Org agenda provides a nice viewing for schedules. With org mode it's
+a very tidy way to manage your time.
#+begin_src emacs-lisp
-(use-package org-msg
- :hook (message-mode-hook . org-msg-mode)
+(use-package org-agenda
+ :after (org evil)
+ :straight nil
+ :init
+ (setq org-agenda-files (list (expand-file-name "~/Text") (expand-file-name "~/Text/Notes"))
+ org-agenda-window-setup 'current-window
+ org-agenda-skip-deadline-prewarning-if-scheduled t)
:config
- (setq org-msg-options "html-postamble:nil H:5 num:nil ^:{} toc:nil author:nil email:nil \\n:t tex:dvipng"
- org-msg-greeting-name-limit 3)
-
- (add-to-list 'org-msg-enforce-css
- '(img latex-fragment-inline
- ((transform . ,(format "translateY(-1px) scale(%.3f)"
- (/ 1.0 (if (boundp 'preview-scale)
- preview-scale 1.4))))
- (margin . "0 -0.35em")))))
+ (evil-set-initial-state 'org-agenda-mode 'normal)
+ :general
+ (leader
+ "fa" (proc (interactive) (find-file (car org-agenda-files)))
+ "aa" #'org-agenda)
+ (nmmap
+ :keymaps 'org-agenda-mode-map
+ "J" #'org-agenda-later
+ "K" #'org-agenda-earlier
+ "t" #'org-agenda-todo
+ "." #'org-agenda-goto-today
+ "," #'org-agenda-goto-date
+ "q" #'org-agenda-quit
+ "r" #'org-agenda-redo))
+#+end_src
+*** Org clock-in
+Org provides a nice timekeeping system that allows for managing how
+much time is taken per task. It even has an extensive reporting
+system to see how much time you spend on specific tasks or overall.
+#+begin_src emacs-lisp
+(use-package org-clock
+ :after org
+ :straight nil
+ :init
+ (defvar +org/clock-out-toggle-report nil
+ "Non-nil means update the first clock report in the file every
+time a clock out occurs.")
+ :config
+ (advice-add #'org-clock-out
+ :after
+ (proc (interactive)
+ (if +org/clock-out-toggle-report
+ (org-clock-report t))))
+ :general
+ (local-leader
+ :keymaps 'org-mode-map
+ :infix "c"
+ "c" #'org-clock-in
+ "o" #'org-clock-out
+ "r" #'org-clock-report
+ "t" (proc (interactive)
+ (setq-local +org/clock-out-toggle-report
+ (not +org/clock-out-toggle-report)))))
#+end_src
*** Org on save
If ~+org/compile-to-pdf-on-save-p~ is non-nil, then compile to
@@ -2461,7 +2496,28 @@ crash (like the async handler for org-export). Works really well with
(start-process-shell-command "" "*pdflatex*" (concat "pdflatex -shell-escape "
(org-latex-export-to-latex)))))
#+end_src
-*** Evil Org
+*** Org message
+Org message allows for the use of org mode when composing mails,
+generating HTML multipart emails. This integrates the WYSIWYG
+experience with mail in Emacs while also providing powerful text
+features with basically no learning curve (as long as you've already
+learnt the basics of org).
+
+#+begin_src emacs-lisp
+(use-package org-msg
+ :hook (message-mode-hook . org-msg-mode)
+ :config
+ (setq org-msg-options "html-postamble:nil H:5 num:nil ^:{} toc:nil author:nil email:nil \\n:t tex:dvipng"
+ org-msg-greeting-name-limit 3)
+
+ (add-to-list 'org-msg-enforce-css
+ '(img latex-fragment-inline
+ ((transform . ,(format "translateY(-1px) scale(%.3f)"
+ (/ 1.0 (if (boundp 'preview-scale)
+ preview-scale 1.4))))
+ (margin . "0 -0.35em")))))
+#+end_src
+*** Org for evil
Evil org for some nice bindings.
#+begin_src emacs-lisp
(use-package evil-org
@@ -2480,21 +2536,15 @@ reveal.js. Pretty nifty and it's easy to use.
*** Org fragtog
Toggle latex fragments in org mode so you get fancy maths symbols. I
use latex a bit in org mode as it is the premier way of getting
-mathematical symbols and text rendered and compiled, but org mode >
-latex.
+mathematical symbols rendered, but org mode > latex.
-As Org mode has the ability to accept arbitrary inputs of Latex
-(through escaped (square) brackets), allowing me to observe how they
-look is nice to have.
+Delimited environments are aplenty, escaped brackets and dollar signs
+are my favourite. Here's a snippet:
+$\int_{-\infty}^{\infty}e^{-x^2}dx = \sqrt{\pi}$.
#+begin_src emacs-lisp
(use-package org-fragtog
:hook (org-mode-hook . org-fragtog-mode))
#+end_src
-*** Org pretty tags
-#+begin_src emacs-lisp
-(use-package org-pretty-tags
- :hook (org-mode-hook . org-pretty-tags-mode))
-#+end_src
*** Org superstar
Org superstar adds cute little Unicode symbols for headers, much
better than the default asterisks.
@@ -2502,62 +2552,6 @@ better than the default asterisks.
(use-package org-superstar
:hook (org-mode-hook . org-superstar-mode))
#+end_src
-*** Org agenda
-Org agenda provides a nice viewing for schedules. With org mode it's
-a very tidy way to manage your time.
-#+begin_src emacs-lisp
-(use-package org-agenda
- :after (org evil)
- :straight nil
- :init
- (setq org-agenda-files (list (expand-file-name "~/Text") (expand-file-name "~/Text/Notes"))
- org-agenda-window-setup 'current-window
- org-agenda-skip-deadline-prewarning-if-scheduled t)
- :config
- (evil-set-initial-state 'org-agenda-mode 'normal)
- :general
- (leader
- "fa" (proc (interactive) (find-file (car org-agenda-files)))
- "aa" #'org-agenda)
- (nmmap
- :keymaps 'org-agenda-mode-map
- "J" #'org-agenda-later
- "K" #'org-agenda-earlier
- "t" #'org-agenda-todo
- "." #'org-agenda-goto-today
- "," #'org-agenda-goto-date
- "q" #'org-agenda-quit
- "r" #'org-agenda-redo))
-#+end_src
-*** Org clock-in
-Org provides a nice timekeeping system that allows for managing how
-much time is taken per task. It even has an extensive reporting
-system to see how much time you spend on specific tasks or overall.
-#+begin_src emacs-lisp
-(use-package org-clock
- :after org
- :straight nil
- :init
- (defvar +org/clock-out-toggle-report nil
- "Non-nil means update the first clock report in the file every
-time a clock out occurs.")
- :config
- (advice-add #'org-clock-out
- :after
- (proc (interactive)
- (if +org/clock-out-toggle-report
- (org-clock-report t))))
- :general
- (local-leader
- :keymaps 'org-mode-map
- :infix "c"
- "c" #'org-clock-in
- "o" #'org-clock-out
- "r" #'org-clock-report
- "t" (proc (interactive)
- (setq-local +org/clock-out-toggle-report
- (not +org/clock-out-toggle-report)))))
-#+end_src
** C/C++
Setup for C and C++ modes via the cc-mode package. C and C++ are
great languages for general purpose programming. My preferred choice