From c4f024a6aef7661370904b9f0a488b8739ba35c4 Mon Sep 17 00:00:00 2001 From: Max Christian Pohle Date: Sun, 2 Dec 2018 01:57:50 +0100 Subject: Fixed colorscheme and display problems - signify sometimes required CTRL-L to display the symbols - separation between windows looked ugly because of the foldcolumns background color- fixed. - added Xresources (can be linked to ~/.Xresources), applies base16 - added xinputrc (can be linked to ~/.xinputrc), makes bash vi-like --- plugin/max-fix-colorschemes.vim | 58 ++++++------ plugin/signify.vim | 10 +-- utils/Xresources | 193 ++++++++++++++++++++++++++++++++++++++++ utils/xinputrc | 3 + vimrc-common | 2 +- 5 files changed, 231 insertions(+), 35 deletions(-) create mode 100644 utils/Xresources create mode 100644 utils/xinputrc diff --git a/plugin/max-fix-colorschemes.vim b/plugin/max-fix-colorschemes.vim index 1624565..abfa11a 100644 --- a/plugin/max-fix-colorschemes.vim +++ b/plugin/max-fix-colorschemes.vim @@ -2,42 +2,43 @@ " COLOR SCHEME: "======================================================================================================================= function! ExtendColorTheme() - highlight! Bold cterm=bold gui=bold - highlight! Italic cterm=italic gui=italic - highlight! Underline cterm=underline gui=underline - highlight! BoldUnderline cterm=bold,underline gui=bold,underline - highlight! BoldItalic cterm=bold,Italic gui=Bold,Italic - highlight! Todo cterm=bold gui=bold guibg=#ffffaa guifg=#000000 - highlight! Error guibg=NONE - highlight! SpellBad cterm=NONE gui=undercurl guibg=NONE guifg=red - - - highlight! link qfSeparator Normal | " reserve one space - highlight! link qfLineNr Normal | " informational line numbers should look different - - highlight! link SpecialKey NonText | " makes tab stop (see listchars) less disturbing - highlight! link EndOfBuffer Ignore - highlight! link WildMenu Search - highlight! link Convention Error - highlight! link VertSplit NonText - - highlight! link VertSplit LineNr - highlight! link Folded LineNr - highlight! link SignColumn LineNr - highlight! link FoldColumn LineNr - - highlight! link PmenuSbar Pmenu - highlight! PmenuThumb cterm=inverse - highlight! MoreMsg cterm=inverse + highlight! Bold cterm=bold gui=bold + highlight! Italic cterm=italic gui=italic + highlight! Underline cterm=underline gui=underline + highlight! BoldUnderline cterm=bold,underline gui=bold,underline + highlight! BoldItalic cterm=bold,Italic gui=Bold,Italic + highlight! Todo cterm=bold gui=bold guibg=#ffffaa guifg=#000000 + highlight! Error cterm=NONE ctermbg=NONE gui=NONE guibg=NONE + highlight! SpellBad cterm=NONE gui=undercurl guibg=NONE guifg=red + highlight! Ignore cterm=NONE ctermbg=NONE ctermfg=NONE gui=NONE guibg=NONE guifg=NONE + highlight! Folded cterm=NONE ctermbg=NONE + highlight! EndOfBuffer cterm=NONE ctermbg=255 ctermfg=255 + + + highlight! link qfSeparator Normal | " reserve one space + highlight! link qfLineNr Normal | " informational line numbers should look different + + highlight! link SpecialKey NonText | " makes tab stop (see listchars) less disturbing + highlight! link WildMenu Search + highlight! link Convention Error + highlight! link VertSplit NonText + + highlight! link VertSplit LineNr + highlight! link SignColumn NonText + highlight! link FoldColumn NonText + + highlight! link PmenuSbar Pmenu + highlight! PmenuThumb cterm=inverse + highlight! MoreMsg cterm=inverse endfunction autocmd ColorScheme * call ExtendColorTheme() +set background=light if filereadable(expand("~/.vimrc_background")) && filereadable(expand("~/.config/base16-shell/colortest")) let g:base16_shell_path = "~/.config/base16-shell/scripts" let base16colorspace = 256 - set background=dark source ~/.vimrc_background else let g:PaperColor_Theme_Options = { @@ -47,6 +48,5 @@ else \ } \ } \ } - set background=light colorscheme PaperColor endif diff --git a/plugin/signify.vim b/plugin/signify.vim index e60cba5..5eeb2b0 100644 --- a/plugin/signify.vim +++ b/plugin/signify.vim @@ -13,11 +13,11 @@ augroup SIGNIFY let g:signify_sign_show_count = 0 if has("multi_byte") && (&enc == 'utf-8' || &enc == 'utf-16' || &enc == 'ucs-4') - let g:signify_sign_add = '⊕' - let g:signify_sign_delete = '⊖' - let g:signify_sign_delete_first_line = '⊖' - let g:signify_sign_change = '⊗' - let g:signify_sign_changedelete = '⊗' + let g:signify_sign_add = '⊕.' + let g:signify_sign_delete = '⊖.' + let g:signify_sign_delete_first_line = '⊖.' + let g:signify_sign_change = '⊗.' + let g:signify_sign_changedelete = '⊗.' endif function! SignifyColorScheme() diff --git a/utils/Xresources b/utils/Xresources new file mode 100644 index 0000000..f536483 --- /dev/null +++ b/utils/Xresources @@ -0,0 +1,193 @@ +! #include "/home/max/.config/base16-xresources/xresources/base16-tomorrow-night.Xresources" +! #include "/home/max/.config/base16-xresources/xresources/base16-google-light.Xresources" +#include "/home/max/.config/base16-xresources/xresources/base16-tomorrow.Xresources" + +urxvt.scrollBar: false +urxvt.background: base00 +urxvt.color0: base00 +urxvt.color1: base00 +urxvt.color2: base00 +urxvt.color3: base00 +urxvt.color4: base00 +urxvt.color5: base00 +urxvt.color6: base00 +urxvt.color7: base00 +urxvt.color8: base00 +urxvt.color9: base00 + +! *Dialog.foreground: foreground +! *Dialog.background: base00 +! *Dialog.Button.foreground: base05 +! *Dialog.Button.background: base00 +! !*Dialog.Button.pointBackground: #EAEAEA +! !*Dialog.Button.clickBackground: #C3C3C3 +! *Dialog.text.foreground: base02 +! *Dialog.text.background: base00 +! *Dialog.topShadowColor: base03 +! *Dialog.bottomShadowColor: base04 + +xscreensaver.logFile:/home/max/xscreensaver.log +xscreensaver.verbose:true +*.newLoginCommand: xset dpms force off + +Xft.antialias: true +Xft.lcdfilter: lcddefault +Xft.hinting: true +Xft.rgba: rgb +Xft.hintstyle: hintfull +Xft.dpi: 96 + +!*passwd.passwdFont: *-helvetica-medium-r-*-*-*-140-*-*-*-iso8859-1 +!*passwd.passwdFont: + +!*font: -*-clean-medium-r-*--12-*-*-*-*-*-*-* +!*font: xft:Bitstream Vera Sans Mono-8 +!*font: *-dejavu sans-bold-r-*-*-*-*-*-*-*-*-*-* +!*font: *-monospace-bold-r-*-*-*-*-*-*-*-*-*-* +!*.font: xft:monaco:bold:size=8 +!*.font: xft:RobotoMono Nerd Font:bold:size=10 +*.passwdFont: xft:monospace +*.font: xft:monospace + + +xscreensaver.overlayTextForeground: #FFFF00 +xscreensaver.overlayTextBackground: #000000 + + +*passwd.thermometer.foreground: #FF0000 +*passwd.thermometer.background: #FFFFFF + +*passwd.heading.label: XScreenSaver %s +*passwd.body.label: This screen is fucked. +*passwd.unlock.label: unfuck +*passwd.login.label: dpms: off +*passwd.user.label: User: +*passwd.thermometer.width: 12 +*passwd.asterisks: True +*passwd.uname: False + + +XLock*mode: image +*image.bitmap: /home/max/.lock.xpm +*image.count: 1 +*image.erasedelay: 0 +XLock*erasedelay: 0 +XLock*icongeometry: 180x180 +! XLock*background: background +! XLock*foreground: foreground +XLock*description: off +XLock*info: + + + + +! ---=== Experiment with making Motif less ugly for DDD ===--- +! (DDD ignores generically-set Motif properties so we must do this) +! TODO (if possible): +! - Hide text cursors in unfocused fields +! - Convert on-hover effect from shadow to background color or border +! - Pick better fonts and check which package provides them + +! Use the lighter background grey from the Lubuntu GTK+ theme +! (Still a cool grey. Eyedropper the Clearlooks warm grey if necessary.) +Ddd*background: #e0e0e0 + +! These had no effect on my system but, from what I read, they help on +! some systems. +Ddd*enableThinThickness: True +Ddd*enableEtchedInMenu: True +Ddd*enableToggleColor: True +Ddd*enableToggleVisual: True + +! Use pure white for white backgrounds like modern widget themes and websites +Ddd*XmText.background: #ffffff +Ddd*XmTextField.background: #ffffff +Ddd*XmList.background: #ffffff +Ddd*GraphEdit.background: #ffffff + +! Thick borders and shadows everywhere are archaic +Ddd*shadowThickness: 1 +Ddd*borderThickness: 0 +Ddd*?*arg*shadowThickness: 1 +Ddd*?*arg*borderThickness: 0 +Ddd*?*buttons*shadowThickness: 1 +Ddd*?*buttons*borderThickness: 0 + +! Un-cramp the menubar, menus, and toolbar to match modern compact sizing +Ddd*menubar*marginTop: 1 +Ddd*menubar*marginBottom: 0 +Ddd*XmMenuShell*marginTop: 2 +Ddd*XmMenuShell*marginBottom: 2 +Ddd*XmMenuShell.?.marginWidth: 2 +Ddd*XmMenuShell.?.marginHeight: 2 +Ddd*toolbar*marginWidth: 5 + +! Compact the menu tear-off buttons +Ddd*XmMenuShell*XmTearOffButton*borderWidth: 0 +Ddd*XmMenuShell*XmTearOffButton*marginHeight: 0 + +! DDD's interpretation of a "toggle button" shouldn't have a raised border +Ddd*XmToggleButton*shadowThickness: 0 +Ddd*XmToggleButton*borderThickness: 0 + +! The menu bar should not have a raised border +Ddd*menubar.shadowThickness: 0 +Ddd*menubar.borderThickness: 0 +Ddd*XmMenuShell*XmTearOffButton*ShadowThickness: 2 + +! ...and we do not want a border around the toolbar to make that stand out +Ddd*main_window.?.borderThickness: 0 +Ddd*main_window.shadowThickness: 0 + +! Drop-down boxes in toolbars do not have raised borders these days +Ddd*toolbar.shadowThickness: 0 +Ddd*toolbar.?.shadowThickness: 1 + +! DDD can sometimes get its GDB settings fatally messed up so duplicate +! GUI-exposed integration defaults here for when I want to nuke ~/.ddd/init +Ddd*cutCopyPasteBindings: KDE +Ddd*selectAllBindings: KDE +Ddd*buttonColorKey: c +Ddd*FlatButtons: on + + +! Good Xaw3d Defaults*customization: -color +*shadowWidth: 3 +*Form.background: gray75 +*MenuButton.background: gray75 +*SimpleMenu.background: gray70 +*TransientShell*Dialog.background: gray70 +*Command.background: gray75 +*Label.background: gray75 +*ScrollbarBackground: grey39 +*Scrollbar*background: gray75 +*Scrollbar*width: 15 +*Scrollbar*height: 15 +*Scrollbar*shadowWidth: 2 +*Scrollbar*cursorName: top_left_arrow +*Scrollbar*pushThumb: false +*shapeStyle: Rectangle +*beNiceToColormap: False +*SmeBSB*shadowWidth: 3 +*highlightThickness: 0 +*topShadowContrast: 40 +*bottomShadowContrast: 60 +! fix up a few of the default X clients who +! now look silly +*xclock*shadowWidth: 0 +*xload*shadowWidth: 0 +*xcalc*shadowWidth: 0 + + +XTerm.vt100.faceName: Monospace:antialias=true +XTerm.vt100.faceSize: 12 +! XTerm.vt100.font: 7x14 +XTerm.vt100.locale: true +XTerm.vt100.utf8Title: true + + +! keepassx colourscheme +keepassx*background: #cfcfcf +keepassx*foreground: #222222 +keepassx2*background: #cfcfcf +keepassx2*foreground: #222222 diff --git a/utils/xinputrc b/utils/xinputrc new file mode 100644 index 0000000..ebd7310 --- /dev/null +++ b/utils/xinputrc @@ -0,0 +1,3 @@ +# im-config(8) generated on Tue, 28 Feb 2017 13:21:48 +0100 +run_im ibus +# im-config signature: ec6901ebc5d2dcf71d14062c6968658e - diff --git a/vimrc-common b/vimrc-common index 7eb499f..21df101 100644 --- a/vimrc-common +++ b/vimrc-common @@ -160,7 +160,7 @@ set foldcolumn=2 | " I think I don't need this second indicator " set foldmethod=syntax | " foldlevel: syntax, indent, manual / foldmethod=syntax makes Vim incredible slow set foldnestmax=1 | " top level folding only set foldopen=block,hor,search | " when do we unfold? -set foldtext=printf('%*s%.*S',indent(v:foldstart),'',&textwidth-indent(v:foldstart),substitute(substitute(join(getline(v:foldstart,v:foldend),'\ '),'[[:space:]]\\+','\ ','g'),'^[[:space:]*]','','g')) +set foldtext=printf('%*s%.*S',indent(v:foldstart),'',&textwidth-indent(v:foldstart),substitute(substitute(join(getline(v:foldstart,v:foldend),'\ '),'[[:space:]*/]\\+','\ ','g'),'^[[:space:]*]','','g')) " works ... " set foldexpr=match(synIDattr(synID(v:lnum,indent(v:lnum)+1,0),'name'),'Comment')>-1 -- cgit v1.2.3