Coder Social home page Coder Social logo

org-lang's Introduction

org-lang

1 Overview

This package implements an easy way to automate the switching of dictionaries in org-mode. And if it doesn’t work automatically or you have to change it in the same buffer, org-lang provides a simple interface with optional ivy- and helm-interface to change the dictionary by hand.

2 Features

  • automatic recognition of languages by the #+LANGUAGE: tag
  • interacitve menu with integration for ivy and helm

3 Requirements

This package is just a simplification and automation for ispell. You have to make sure that you have configured ispell and optionally flyspell.

Also you have to have an installed spell checker. I have tested it with aspell. Also may have to install the dictionaries on your own.

4 Installation

Org-lang is looking for the #+LANGUAGE: string in the buffer. The symbol that follows this string is then given to ispell. But first it checks if it is in the list of specified languages.

Please make sure that you have set ispell-program-name to the installed spell checker.

The interactive selection menu (org-lang-selector) is per default bound to C-c l.

This is my personal configuration:

(use-package org-lang
  :ensure t
  :quelpa (org-lang
	   :repo domse007/org-lang
	   :fetcher github)
  :custom ((org-lang-fallback-lang "de_CH")
	   (org-lang-installed-langs
	    '("de_CH" "de_DE" "fr_CH" "en_US"))
	   (org-lang-prefered-completion 'helm)
	   (org-lang-check-after-enable t))
  :hook ((org-mode . org-lang-mode)
	 (org-mode . org-lang-get-buffer-lang)))

It is not on melpa, so you have to install it with git or use quelpa.

The following variables can be customized.

  • org-lang-fallback-lang: It takes a String with the language that the is used, if org-lang couldn’t automatically detect a language. The reported string from the buffer and a string from the org-lang-installed-langs don’t have to match exactly.
  • org-lang-installed-langs: It takes a list with the languages you wish to use.
  • org-lang-prefered-completion: It takes a symbol with the name of the your preferred completion frontend. Currently =’default= for use without any completion frontend, =’ivy= and =’helm= are supported.
  • org-lang-check-after-enable: It takes a boolean value. If t, it calls flyspell-buffer after calling ispell-change-dictionary.

5 License

GPLv3

org-lang's People

Contributors

domse007 avatar

Watchers

James Cloos avatar  avatar

org-lang's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.