;; (fringe :background "black" :foreground "gray90")
(fringe :background "gray80")
(ff/date-info-face :foreground "white")
- (ff/battery-info-face :foreground "black")
+ (ff/battery-info-face :foreground "blue")
(ff/battery-info-alarm-face :foreground "red")
;; (ff/mail-alarm-face :foreground "white" :background "red2")
;; (alarm-vc-face :foreground "black" :background "yellow" :weight 'normal)
(defun ff/show-compilation-buffer-split-window ()
"Split the window vertically and show the compilation buffer in the newly created right one"
(interactive)
- (show-buffer (split-window-right) "*compilation*")
+
+ (let ((b (get-buffer "*compilation*")))
+ (if b (show-buffer (split-window-right) b)
+ (error "Cannot find a compilation buffer"))
+ )
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
)
)
- ;; (`unknown "✱")
- (`unknown "F")
+ (`unknown (propertize "☼" 'face 'ff/battery-info-face))
+ ;; (`unknown "☼")
+ ;; (`unknown "F")
(_ "?"))
(error nil))
)
(defun ff/save-window-configuration (universal) (interactive "P")
(if universal
- (setq ff/window-configuration (current-window-configuration))
+ (progn
+ (setq ff/window-configuration (current-window-configuration))
+ (message "Window configuration stored")
+ )
(set-window-configuration ff/window-configuration))
)
(goto-char (point-min))
(insert "%% -*- mode: latex; mode: reftex; mode: flyspell; coding: utf-8; tex-command: \"pdflatex.sh\" -*-
-\\documentclass[12pt,a4paper,twoside]{article}
+\\documentclass[11pt,a4paper,twoside]{article}
\\usepackage[a4paper,top=2.5cm,bottom=2cm,left=2.5cm,right=2.5cm]{geometry}
\\usepackage[utf8]{inputenc}
\\usepackage{amsmath}
\\usepackage{amssymb}
\\usepackage[pdftex]{graphicx}
-\\usepackage{microtype}
\\usepackage[colorlinks=true,linkcolor=blue,urlcolor=blue,citecolor=blue]{hyperref}
\\usepackage{tikz}
+\\usepackage[round]{natbib}
+\\usepackage{cmbright}
\\setlength{\\parindent}{0cm}
\\setlength{\\parskip}{12pt}
-\\renewcommand{\\baselinestretch}{1.3}
+%\\renewcommand{\\baselinestretch}{1.3}
%\\setlength{\\tabcolsep}{0pt}
%\\renewcommand{\\arraystretch}{1.0}
\\def\\argmax{\\operatornamewithlimits{argmax}}
\\def\\argmin{\\operatornamewithlimits{argmin}}
-%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
-%% Open sans font
-%%\\usepackage[default]{opensans}
-%%\\usepackage{cmbright}
-%%\\renewcommand{\\familydefault}{fos}
-%%\\renewcommand{\\seriesdefault}{l}
-%%\\renewcommand{\\bfdefault}{sb}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% The \\todo command
\\newcounter{nbdrafts}
(goto-char (point-max))
(insert "
+\\bibliographystyle{abbrvnat}
+
+\\bibliography{dlc}
+
+\\checknbdrafts
+
\\end{document}
"))
(latex-mode))
(define-key global-map [(shift f1)] 'compile)
(define-key global-map [f2] 'next-error)
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; Horrible hack
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+
+(defun dont-delay-compile-warnings (fun type &rest args)
+ (if (eq type 'bytecomp)
+ (let ((after-init-time t))
+ (apply fun type args))
+ (apply fun type args)))
+(advice-add 'display-warning :around #'dont-delay-compile-warnings)
+
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Related to mail
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Runs in server mode, so that emacsclient works
-(server-start)
+;; ;;(server-start)
-(defun ff/raise-frame-and-give-focus ()
- (when window-system
- (raise-frame)
- (x-focus-frame (selected-frame))
- (set-mouse-pixel-position (selected-frame) 4 4)
- ))
+;; (defun ff/raise-frame-and-give-focus ()
+ ;; (when window-system
+ ;; (raise-frame)
+ ;; (x-focus-frame (selected-frame))
+ ;; (set-mouse-pixel-position (selected-frame) 4 4)
+ ;; ))
-;; Raises the window when the server is invoked
+;; ;; Raises the window when the server is invoked
-(add-hook 'server-switch-hook 'ff/raise-frame-and-give-focus)
+;; (add-hook 'server-switch-hook 'ff/raise-frame-and-give-focus)