Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6693573
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T05:59:55+00:00 2026-05-26T05:59:55+00:00

In vim I am trying to have it highlight my screen when it goes

  • 0

In vim I am trying to have it highlight my screen when it goes over 80 characters (I am a kernel developer and this is a requirement for kernel code). I am using the following in my .vimrc file to do this

highlight OverLength ctermbg=red ctermfg=white guibg=#59292
match OverLength /\%81v.\+/

which was suggested here: Vim 80 column layout concerns

However, I am colorblind and as a result I cannot use the default colorscheme and see the text on the screen so I change my default colorscheme using :colorscheme torte as well. However, it appears that the colorscheme overrides the highlighting on me (it highlights fine when I don’t have the colorscheme specified, and doesn’t when it is specified).

Does anyone have any ideas on how to make this work with the colorscheme change? Thanks for your help,

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T05:59:56+00:00Added an answer on May 26, 2026 at 5:59 am

    That’s because most color schemes have this line in their beginning:

    hi clear
    

    This clear all highlighting groups created (you created OverLength). This is good, because no colorscheme has every thing set, and colors from the previous scheme used could remain appearing.

    To solve, instead of creating a new group, match this pattern as Error which is a default Vim group, will be present in every color scheme. Change your two lines by one simply:

    match Error /\%81v.\+/
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Basically, what I'm trying to do is have VIM search for dictionary/thesaurus results using
I am trying to install vim with the ruby interpreter. Following this stackoverflow question
I am using vim 7.3 and the NERDTree 4.1 plugin. I have been trying
I have been trying to learn Vim and have been using it for 2
Using Vim, I'm trying to pipe text selected in visual mode to a UNIX
I have a vim macro that I keep mistyping, usually when I'm trying to
So recently I have been trying to set up a Vim-based iOS workflow. I
I have been trying to get slimv (http://www.vim.org/scripts/script.php?script_id=2531) working for a while now, but
Possible Duplicate: How can I configure Vim to compile C code using Borland’s compiler
I'm a vim user and have recently been trying out emacs for fun. I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.