Ejemplo n.º 1
0
def test_color_pack2rgb(pack, res):
    """Unit test for color_pack2rgb"""

    assert color_pack2rgb(pack) == res
Ejemplo n.º 2
0
    def _get_background_color(self):
        """Returns background color rgb tuple of right line"""

        color = self.cell_attributes[self.key]["bgcolor"]
        return tuple(c / 255.0 for c in color_pack2rgb(color))
Ejemplo n.º 3
0
def test_color_pack2rgb(pack, res):
    """Unit test for color_pack2rgb"""

    assert color_pack2rgb(pack) == res
Ejemplo n.º 4
0
    def _get_text_color(self):
        """Returns text color rgb tuple of right line"""

        color = self.code_array.cell_attributes[self.key]["textcolor"]
        return tuple(c / 255.0 for c in color_pack2rgb(color))
Ejemplo n.º 5
0
    def _get_right_line_color(self):
        """Returns color rgb tuple of right line"""

        color = self.cell_attributes[self.key]["bordercolor_right"]
        return tuple(c / 255.0 for c in color_pack2rgb(color))
Ejemplo n.º 6
0
    def _get_background_color(self):
        """Returns background color rgb tuple of right line"""

        color = self.cell_attributes[self.key]["bgcolor"]
        return tuple(c / 255.0 for c in color_pack2rgb(color))
Ejemplo n.º 7
0
    def _get_text_color(self):
        """Returns text color rgb tuple of right line"""

        color = self.code_array.cell_attributes[self.key]["textcolor"]
        return tuple(c / 255.0 for c in color_pack2rgb(color))
Ejemplo n.º 8
0
    def _get_right_line_color(self):
        """Returns color rgb tuple of right line"""

        color = self.cell_attributes[self.key]["bordercolor_right"]
        return tuple(c / 255.0 for c in color_pack2rgb(color))