Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 513192 - Update editor colours for occurrences and warning annotations
Summary: Update editor colours for occurrences and warning annotations
Status: RESOLVED FIXED
Alias: None
Product: Orion
Classification: ECD
Component: Client (show other bugs)
Version: 13.0   Edit
Hardware: PC Mac OS X
: P1 normal (vote)
Target Milestone: 14.0   Edit
Assignee: Silenio Quarti CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-03-06 13:10 EST by Michael Rennie CLA
Modified: 2017-03-07 12:26 EST (History)
2 users (show)

See Also:
snorthov: review+


Attachments
screenshot of #b27f21 as warning squigles (43.41 KB, image/png)
2017-03-07 10:43 EST, Silenio Quarti CLA
no flags Details
patch that updates the occurrences colors and warning squiggles (2.85 KB, patch)
2017-03-07 10:58 EST, Silenio Quarti CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Rennie CLA 2017-03-06 13:10:10 EST
Occurrences colours should be changed from the bright yellow to be match that of Eclipse (they have removed the yellow as a default for occurrences, so we should follow suite)

The warning annotation colour should be updated to something more visible - in the light theme, it can be hard to see the warning squiggle in the editor.
Comment 1 Silenio Quarti CLA 2017-03-07 10:43:02 EST
Created attachment 267142 [details]
screenshot of #b27f21 as warning squigles
Comment 2 Silenio Quarti CLA 2017-03-07 10:51:41 EST
JSfiddle snippet to generate data URLs for squigles:

function create(background) {
var canvas = document.getElementById("test");
if (!canvas) {
      canvas = document.createElement("canvas");
      canvas.id = "test";
      canvas.width = 4;
      canvas.height = 3;
      canvas.style.style = "visibility:hidden";
      document.body.appendChild(canvas);
}
canvas.style.backgroundColor = background;
var width = 4;
var height = 3;
//AABBGGRR
function RGBToInt(rgbStr) {
		var rgb = rgbStr.match(/\d+/g);
		var r = parseInt(rgb[0]);
		var g = parseInt(rgb[1]);
		var b = parseInt(rgb[2]);
    return r + (g << 8) + (b << 16);
}
var color = 0xFF000000 + RGBToInt(window.getComputedStyle(canvas, null).getPropertyValue("background-color"));
canvas.style.width = width + "px";
canvas.style.height = height + "px";
ctx = canvas.getContext("2d");
myImage = ctx.getImageData(0, 0, width, height);
myImage.data[8+0] = (color >> 0) & 0xFF;
myImage.data[8+1] = (color >> 8) & 0xFF;
myImage.data[8+2] = (color >> 16) & 0xFF;
myImage.data[8+3] = (color >> 24) & 0xFF;
myImage.data[20+0] = (color >> 0) & 0xFF;
myImage.data[20+1] = (color >> 8) & 0xFF;
myImage.data[20+2] = (color >> 16) & 0xFF;
myImage.data[20+3] = (color >> 24) & 0xFF;
myImage.data[28+0] = (color >> 0) & 0xFF;
myImage.data[28+1] = (color >> 8) & 0xFF;
myImage.data[28+2] = (color >> 16) & 0xFF;
myImage.data[28+3] = (color >> 24) & 0xFF;
myImage.data[32+0] = (color >> 0) & 0xFF;
myImage.data[32+1] = (color >> 8) & 0xFF;
myImage.data[32+2] = (color >> 16) & 0xFF;
myImage.data[32+3] = (color >> 24) & 0xFF;
ctx.putImageData(myImage, 0, 0);
console.log(canvas.toDataURL());

var div = document.createElement("span");
div.style.backgroundRepeat = "repeat-x";
div.style.backgroundPosition = "left bottom";
div.innerHTML = "Testing";
div.style.backgroundImage = "url(" + canvas.toDataURL() + ")";
document.body.appendChild(div);
}

create("#b27f21")
create("red")
create("blue")
Comment 3 Silenio Quarti CLA 2017-03-07 10:58:51 EST
Created attachment 267143 [details]
patch that updates the occurrences colors and warning squiggles