From 68f3c10055caea4e647ee818ddfc157ec3c325ac Mon Sep 17 00:00:00 2001 From: daboe01 Date: Sat, 25 Jun 2016 20:49:56 +0200 Subject: [PATCH] fixed: only one color was supported on the pasteboard --- AppKit/CPTextView/_CPRTFParser.j | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/AppKit/CPTextView/_CPRTFParser.j b/AppKit/CPTextView/_CPRTFParser.j index bbe14e999..f6f0bac94 100644 --- a/AppKit/CPTextView/_CPRTFParser.j +++ b/AppKit/CPTextView/_CPRTFParser.j @@ -534,7 +534,7 @@ var kRgsymRtf = { blue = [oldColor blueComponent]; _colorArray.pop(); - _colorArray.push([CPColor colorWithRed: parseInt(param) / 255 green:green blue:blue alpha:1.0]); + _colorArray.push([CPColor colorWithRed:parseInt(param) / 255 green:green blue:blue alpha:1.0]); break; case "green": @@ -543,7 +543,7 @@ var kRgsymRtf = { blue = [oldColor blueComponent]; _colorArray.pop(); - _colorArray.push([CPColor colorWithRed: red green: parseInt(param) / 255 blue:blue alpha:1.0]); + _colorArray.push([CPColor colorWithRed:red green: parseInt(param) / 255 blue:blue alpha:1.0]); break; case "blue": @@ -552,7 +552,8 @@ var kRgsymRtf = { red = [oldColor redComponent]; _colorArray.pop(); - _colorArray.push([CPColor colorWithRed: red green:green blue:parseInt(param) / 255 alpha:1.0]); + _colorArray.push([CPColor colorWithRed:red green:green blue:parseInt(param) / 255 alpha:1.0]); + _colorArray.push([CPColor blackColor]); // placeholder for next color break; case "cf": // change foreground color