title: Convert HTML HEX Color or RGB tuple to X11 color
body: <p>I'm searching for a single function to convert RGB tuple (<code>255, 255, 255</code>) or HTML hex (<code>#FFFFFF</code>) to X11 color (<code>0...255 int</code>) to manage colors in Unix terminal. I've looked over the internet but I didn't find anything like that, so I'm asking for code or link to a website that contains code or information about how I can do this in Python.</p>