Communities

Writing
Writing
Codidact Meta
Codidact Meta
The Great Outdoors
The Great Outdoors
Photography & Video
Photography & Video
Scientific Speculation
Scientific Speculation
Cooking
Cooking
Electrical Engineering
Electrical Engineering
Judaism
Judaism
Languages & Linguistics
Languages & Linguistics
Software Development
Software Development
Mathematics
Mathematics
Christianity
Christianity
Code Golf
Code Golf
Music
Music
Physics
Physics
Linux Systems
Linux Systems
Power Users
Power Users
Tabletop RPGs
Tabletop RPGs
Community Proposals
Community Proposals
tag:snake search within a tag
answers:0 unanswered questions
user:xxxx search by author id
score:0.5 posts with 0.5+ score
"snake oil" exact phrase
votes:4 posts with 4+ votes
created:<1w created < 1 week ago
post_type:xxxx type of post
Search help
Notifications
Mark all as read See all your notifications »
Q&A

Welcome to Software Development on Codidact!

Will you help us build our independent community of developers helping developers? We're small and trying to grow. We welcome questions about all aspects of software development, from design to code to QA and more. Got questions? Got answers? Got code you'd like someone to review? Please join us.

Post History

75%
+4 −0
Q&A How do I type something different at each cursor when using multi-cursor editing in VS Code?

For example, say I have this CSS: .ocean {} .land {} .sky {} I want to give each of them a background-color, so I use multi-cursors and type: .ocean { background-color: } .land { background...

2 answers  ·  posted 1mo ago by wjandrea‭  ·  last activity 1mo ago by user253751‭

Question vs-code multi-cursor
#1: Initial revision by user avatar wjandrea‭ · 2026-08-09T23:37:54Z (about 1 month ago)
How do I type something different at each cursor when using multi-cursor editing in VS Code?
For example, say I have this CSS:

```css
.ocean {}
.land {}
.sky {}
```

I want to give each of them a `background-color`, so I use [multi-cursors](https://code.visualstudio.com/docs/editing/codebasics#_multiple-selections-multi-cursor) and type:

```css
.ocean { background-color: }
.land { background-color: }
.sky { background-color: }
```

Now how do I type a different colour for each one? Say `blue`, `green`, `lightblue`.

I would love to have a keybinding to rotate through the cursors and type one colour at a time, then go right back to multi-cursor editing so I could add the trailing semicolon and more CSS declarations inside each block.

The best workaround I've found is to open a text file and type one item per line, then copy-paste it into the CSS. Thankfully multi-cursors handles this correctly.

```none
blue
green
lightblue
```

_Note: This is based on [this Stack Overflow question](https://stackoverflow.com/questions/49248296/is-it-possible-to-type-different-value-for-multiple-cursors "Is it possible to type different value for multiple cursors?"), but more specific (not a sequence of numbers, and not about Sublime). I'll post my own answer here shortly._