Professional Documents
Culture Documents
Emacs
Emacs
;; ORG- MODE
(require 'ido)
(ido-mode)
(ido-everywhere)
;; which-key
(require 'which-key)
(which-key-mode)
(setq which-key-popup-type 'minibuffer)
;;Fonts
(custom-set-faces)
(defun fontify-frame (frame) (set-frame-parameter frame 'font "Ubuntu Mono-11"))
(fontify-frame nil)
(push 'fontify-frame after-make-frame-functions)
;;(set-default-font "11")
;;fin fonts
;; Theme
(load-theme 'spacemacs-dark t)
;;MELPA MANUAL
(require 'package)
(add-to-list 'package-archives
'("melpa-stable" . "https://stable.melpa.org/packages/") t)
(require 'package)
(let* ((no-ssl (and (memq system-type '(windows-nt ms-dos))
(not (gnutls-available-p))))
(url (concat (if no-ssl "http" "https") "://melpa.org/packages/")))
(add-to-list 'package-archives (cons "melpa" url) t))
(when (< emacs-major-version 24)
(telephone-line-mode 1)
;; Fin telephone Line
;;multiple-cursors
(require 'multiple-cursors)
(global-set-key (kbd "C-S-c C-S-c") 'mc/edit-lines)
(global-set-key (kbd "C->") 'mc/mark-next-like-this)
(global-set-key (kbd "C-<") 'mc/mark-previous-like-this)
(global-set-key (kbd "C-c C-<") 'mc/mark-all-like-this)
;Julia
(defun my-julia-mode-hooks ()
(require 'julia-shell-mode))
(add-hook 'julia-mode-hook 'my-julia-mode-hooks)
(define-key julia-mode-map (kbd "C-c C-c") 'julia-shell-run-region-or-line)
(define-key julia-mode-map (kbd "C-c C-s") 'julia-shell-save-and-go)
(defun julia-fill-string ()
"Fill a docstring, preserving newlines before and after triple quotation marks."
(interactive)
(if (and transient-mark-mode mark-active)
(fill-region (region-beginning) (region-end) nil t)
(cl-flet ((fill-if-string ()
(when (or (looking-at (rx "\"\"\""
(group
(*? (or (not (any "\\"))
(seq "\\"
anything))))
"\"\"\""))
(looking-at (rx "\""
(group
(*? (or (not (any "\\"))
(seq "\\"
anything))))
"\"")))
(let ((start (match-beginning 1))
(end (match-end 1)))
;; (ess-blink-region start end)
(fill-region start end nil nil nil)))))
(save-excursion
(let ((s (syntax-ppss)))
(when (fourth s) (goto-char (ninth s))))
(fill-if-string)))))
;;Julia fin