From a7c82c865c3287202f9825b5e081ea1fa3efa2aa Mon Sep 17 00:00:00 2001 From: Bozhidar Batsov Date: Wed, 8 Apr 2020 10:34:55 +0300 Subject: [PATCH] [Docs] Document the company-mode setup --- doc/modules/company.md | 28 ++++++++++++++++++++++++++++ doc/modules/index.md | 2 +- mkdocs.yml | 1 + 3 files changed, 30 insertions(+), 1 deletion(-) create mode 100644 doc/modules/company.md diff --git a/doc/modules/company.md b/doc/modules/company.md new file mode 100644 index 0000000..f58d08f --- /dev/null +++ b/doc/modules/company.md @@ -0,0 +1,28 @@ +# Prelude Company + +!!! Note + + This module is enabled by default. + +[company](https://company-mode.github.io/) is a completion library. + +This module simply provides some reasonable defaults for it and enables `company-mode`: + +``` +(setq company-idle-delay 0.5) +(setq company-show-numbers t) +(setq company-tooltip-limit 10) +(setq company-minimum-prefix-length 2) +(setq company-tooltip-align-annotations t) +;; invert the navigation direction if the the completion popup-isearch-match +;; is displayed on top (happens near the bottom of windows) +(setq company-tooltip-flip-when-above t) + +(global-company-mode 1) +``` + +You can adjust the configuration further in your personal config. + +`company-mode` has [many extensions](https://github.com/company-mode/company-mode/wiki/Third-Party-Packages) +for various programming languages. +Some of Prelude's modules will install and enable the relevant extensions when necessary. diff --git a/doc/modules/index.md b/doc/modules/index.md index 9278a2d..cc53ffd 100644 --- a/doc/modules/index.md +++ b/doc/modules/index.md @@ -83,7 +83,7 @@ The following programming languages have enhanced support in Prelude: ## Other Modules -- company +- [Company](company.md) - [ERC](erc.md) - evil - helm diff --git a/mkdocs.yml b/mkdocs.yml index c50cf36..8ffbbc6 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -9,6 +9,7 @@ pages: - Configuration: configuration.md - Modules: - Overview: modules/index.md + - Company: modules/company.md - ERC: modules/erc.md - Programming: modules/programming.md - Python: modules/python.md