Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Double quotes in vim/ubuntu?

Tags:

c

linux

vim

I apologize profusely for the incredibly newbish question I'm about to ask, but for some reason, my brain's locked up:

I'm trying to code in C on gvim on a virtual machine running Ubuntu, but my Hello World throws compiler errors which I suspect has to do with the quotes being different ascii(unicode?) codes than standard quotes. It doesn't recognize "Hello World" as a string and says "stray \250 in program" as well as "stray \302 in program" each twice.

To type a double quote, I have to hold down Shift and double-tap the quote key. This seems to be a global setting for all programs (terminal, open office, etc.)

Am I correct in assuming it's a problem with quotes, and if so, would any of you happen to know a solution to my problem?

like image 523
Matt Boehm Avatar asked Dec 23 '22 13:12

Matt Boehm


1 Answers

It sounds like you've got the wrong keyboard map set up. I got the same symptoms as you with a "UK (international with deadkeys)" keyboard map. Changed it to a standard UK one and it worked fine.

HTH

Rob

like image 65
RobS Avatar answered Jan 08 '23 04:01

RobS