XcodeColorSense banner
onmyway133 onmyway133

XcodeColorSense

Development community

Description

:balloon: An Xcode plugin that makes working with color easier

Installation

This entry records only its repository, not the path inside it, so there is no exact command to give. Open the source below and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

README

XcodeColorSense

An Xcode plugin that makes working with color easier. Inspired by [ColorSense-for-Xcode](https://github.com/omz/ColorSense-for-Xcode) with extra care for Hex color

![](Screenshots/Banner.png)

Features

  • Show color preview as you type or select
  • Works for UIColor, NSColor

![](Screenshots/XcodeColorSense.gif)

Matchers

  • Hex Matcher
let _ = NSColor.hex("#FFAABB")
let _ = UIColor(hex: 0xFFAABB)
  • RGBA Matcher
let _ = UIColor(red: 1.0f, green: 240/255, blue: 0.8, alpha: 0.95)
  • Preset Matcher
let _ = NSColor.redColor()

Extensible

Add your own color handler by conforming to `Matcher`

protocol Matcher {
  func check(line: String, selectedText: String) -> (color: NSColor, range: NSRange)?
}

Installation

Manually

  • Build the project. The plugin will be in ~/Library/Application Support/Developer/Shared/Xcode/Plug-ins
  • Restart Xcode

Alcatraz

Licence

This project is released under the MIT license. See LICENSE.md.