From f96e07612b34a505c70b34bbd961104b3c3371a8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20Av=C3=A9?= Date: Fri, 12 Nov 2021 12:30:00 +0100 Subject: [PATCH] Add rofi config --- .vimrc | 60 +++++++++++++-------- rofi/config.rasi | 7 +++ rofi/material-ocean.rasi | 109 +++++++++++++++++++++++++++++++++++++++ 3 files changed, 154 insertions(+), 22 deletions(-) create mode 100644 rofi/config.rasi create mode 100644 rofi/material-ocean.rasi diff --git a/.vimrc b/.vimrc index c49a69e..4f1d16c 100644 --- a/.vimrc +++ b/.vimrc @@ -1,18 +1,17 @@ set nocompatible +syntax on let VIMHOME = split(&rtp, ",")[0] let $VIMHOME = VIMHOME " vim-plug call plug#begin(VIMHOME."/plugs") -Plug 'lervag/vimtex' -Plug 'posva/vim-vue' -Plug 'neovimhaskell/haskell-vim' -Plug 'nvie/vim-flake8' -Plug 'roxma/nvim-yarp' -Plug 'roxma/vim-hug-neovim-rpc' +" Plug 'OmniSharp/omnisharp-vim' +Plug 'Valloric/YouCompleteMe' +Plug 'vimwiki/vimwiki' +Plug 'rhysd/vim-grammarous' Plug 'ConradIrwin/vim-bracketed-paste' +Plug 'NLKNguyen/papercolor-theme' Plug 'Shougo/deoplete.nvim' -" Plug 'Valloric/YouCompleteMe' Plug 'christoomey/vim-tmux-navigator' Plug 'cohama/lexima.vim', {'do': 'sed -i \"s/has(.nvim.) && //\" autoload/lexima/insmode.vim'} Plug 'editorconfig/editorconfig-vim' @@ -21,16 +20,23 @@ Plug 'hdima/python-syntax' Plug 'jeetsukumaran/vim-buffergator' Plug 'kien/ctrlp.vim' Plug 'kristijanhusak/vim-hybrid-material' -Plug 'neoclide/coc.nvim', {'branch': 'release'} -Plug 'NLKNguyen/papercolor-theme' +Plug 'lervag/vimtex' +" Plug 'neoclide/coc.nvim', {'branch': 'master', 'do': 'yarn install --frozen-lockfile'} +" Plug 'neoclide/coc.nvim', {'branch': 'release'} +Plug 'neovimhaskell/haskell-vim' Plug 'nixprime/cpsm', {'do': './install.sh'} +Plug 'nvie/vim-flake8' Plug 'octol/vim-cpp-enhanced-highlight' Plug 'pangloss/vim-javascript' +Plug 'posva/vim-vue' +Plug 'roxma/nvim-yarp' +Plug 'roxma/vim-hug-neovim-rpc' Plug 'tmux-plugins/vim-tmux' Plug 'tmux-plugins/vim-tmux-focus-events' Plug 'tomtom/tcomment_vim' Plug 'vim-airline/vim-airline' Plug 'vim-airline/vim-airline-themes' +Plug 'vim-scripts/indentpython.vim' call plug#end() let g:ycm_global_ycm_extra_conf = '~/.vim/.ycm_extra_conf.py' @@ -46,8 +52,13 @@ nnoremap k gk " don't store .swp files in the file's own directory " neither for .ext~ files -set directory=/home/billie/.vim/tmp/ -set backupdir=/home/billie/.vim/tmp/ +set directory=/home/user/.vim/tmp/ +set backupdir=/home/user/.vim/tmp/ + +" VimWiki +let g:vimwiki_key_mappings = { 'table_mappings': 0 } +let g:vimwiki_markdown_link_ext = 1 +autocmd FileType vimwiki setlocal shiftwidth=2 softtabstop=2 expandtab " Autoindent for filetype filetype plugin indent on @@ -101,6 +112,10 @@ nnoremap :noh " Text wrapping set lbr +" Vimtex + +let g:tex_flavor = 'latex' + " Tabs if has("autocmd") filetype plugin indent on @@ -151,7 +166,8 @@ vnoremap u y autocmd VimLeave * call system("xsel -ib", getreg('+')) " Automatically remove trailing spaces -autocmd BufWritePre * :%s/\s\+$//e +let blacklist = ['vimwiki'] +autocmd BufWritePre * if index(blacklist, &ft) < 0 | :%s/\s\+$//e " Use deoplete. autocmd FileType python let g:deoplete#enable_at_startup = 1 @@ -182,9 +198,9 @@ Ext 'coc-snippets' Ext 'coc-emoji' Ext 'coc-highlight' Ext 'coc-emmet' +Ext 'coc-omnisharp' Ext 'coc-vimtex' Ext 'coc-json' -Ext 'coc-tabnine' Ext 'coc-java' delc Ext @@ -192,12 +208,12 @@ delc Ext " Tab for completion " use for trigger completion and navigate to the next complete item -function! s:check_back_space() abort - let col = col('.') - 1 - return !col || getline('.')[col - 1] =~ '\s' -endfunction - -inoremap - \ pumvisible() ? "\" : - \ check_back_space() ? "\" : - \ coc#refresh() +" function! s:check_back_space() abort +" let col = col('.') - 1 +" return !col || getline('.')[col - 1] =~ '\s' +" endfunction +" +" inoremap +" \ pumvisible() ? "\" : +" \ check_back_space() ? "\" : +" \ coc#refresh() diff --git a/rofi/config.rasi b/rofi/config.rasi new file mode 100644 index 0000000..8a52c2b --- /dev/null +++ b/rofi/config.rasi @@ -0,0 +1,7 @@ +configuration { + font: "SF Pro Rounded 15"; + show-icons: true; + theme: "~/.config/rofi/material-ocean.rasi"; + icon-theme: "Papirus"; + kb-cancel: "Shift+Ctrl+Alt+F12,Escape,Alt+F1"; +} diff --git a/rofi/material-ocean.rasi b/rofi/material-ocean.rasi new file mode 100644 index 0000000..4d3ffdc --- /dev/null +++ b/rofi/material-ocean.rasi @@ -0,0 +1,109 @@ +/* + Copyright © Blacksuan19 @ 2020 + part of material ocean colorscheme + licensed under GNU's GPL 3 +*/ + +* { + background: #0f111a; + foreground: #f1f1f1; + selected: #0033a1; + selected-text: #ffffff; +} + +window { + transparency: "real"; + background-color: @background; + text-color: @foreground; + width: 1000px; + height: 500px; +} + +prompt { + enabled: true; + padding: 10px 10px 15px 15px; + background-color: @background; + text-color: @foreground; +} + +textbox-prompt-colon { + expand: false; + background-color: @background; + padding: 4px 0px 0px 6px; +} + +inputbar { + children: [ textbox-prompt-colon, entry ]; + background-color: @background; + text-color: @foreground; + expand: false; + border: 0px 0px 0px 0px; + border-radius: 0px; + border-color: @selected; + margin: 0px 0px 0px 0px; + padding: 0px 0px 4px 0px; + position: center; +} + +entry { + background-color: @background; + text-color: @foreground; + placeholder-color: @foreground; + expand: true; + horizontal-align: 0; + blink: true; + padding: 4px 0px 0px 4px; + font: "SF Pro Rounded 25"; +} + +case-indicator { + background-color: @background; + text-color: @foreground; + spacing: 0; +} + +listview { + background-color: @background; + columns: 1; + spacing: 5px; + cycle: true; + dynamic: true; + layout: vertical; +} + +mainbox { + background-color: @background; + children: [ inputbar, listview ]; + spacing: 20px; + padding: 20px 15px 15px 15px; +} + +element { + background-color: @background; + text-color: @foreground; + orientation: horizontal; + border-radius: 4px; + padding: 6px 6px 6px 6px; +} + +element-text, element-icon { + background-color: inherit; + text-color: inherit; +} + +element-icon { + size: 40px; + border: 10px; +} + +element-text { + padding: 16px 0px 0px 10px; +} + +element selected { + background-color: @selected; + text-color: @selected-text; + border: 0px; + border-radius: 0px; + border-color: @selected; +}