 
 ;;; ..:: LaTeX ::..
 
+(defun danylo/symbol-at-point-with-underscore ()
+  "Get the symbol at current point, with an underscore. Useful for
+swooping inside LaTeX document."
+  (interactive)
+  (let ((table (copy-syntax-table (syntax-table))))
+    (modify-syntax-entry ?_ "w" table)
+    (modify-syntax-entry ?: "w" table)
+    (with-syntax-table table
+      (thing-at-point 'symbol))))
+
 (use-package tex
   ;; https://elpa.gnu.org/packages/auctex.html
   ;; Package for writing and formatting TeX files

			 (add-to-list 'helm-completing-read-handlers-alist
				      '(LaTeX-environment
					. helm-completing-read-default-handler))
			 ))
	 (reftex-mode . (lambda ()
			  ;; Unset C-c /, which conflicts with google-this

  (add-to-list 'LaTeX-verbatim-environments "@pie@shell")
  (add-to-list 'LaTeX-indent-environment-list '("pycode" current-indentation))
  (add-to-list 'LaTeX-indent-environment-list '("pykzmathblock" current-indentation))
  (add-to-list 'LaTeX-indent-environment-list '("@pie@shell" current-indentation)))b

(use-package bibtex
  ;; http://www.jonathanleroux.org/bibtex-mode.html
