Add labeling tests for letter/word spacing
@ -185,6 +185,22 @@ class TestPointBase(object):
|
||||
self.lyr.shadowTransparency = 0
|
||||
self.checkTest()
|
||||
|
||||
def test_letter_spacing(self):
|
||||
# Modified letter spacing
|
||||
font = QFont(self._TestFont)
|
||||
font.setLetterSpacing(QFont.AbsoluteSpacing, 3.5)
|
||||
font.setPointSizeF(30)
|
||||
self.lyr.textFont = font
|
||||
self.checkTest()
|
||||
|
||||
def test_word_spacing(self):
|
||||
# Modified word spacing
|
||||
font = QFont(self._TestFont)
|
||||
font.setPointSizeF(30)
|
||||
font.setWordSpacing(20.5)
|
||||
self.lyr.textFont = font
|
||||
self.checkTest()
|
||||
|
||||
# noinspection PyPep8Naming
|
||||
|
||||
|
||||
|
BIN
tests/testdata/control_images/expected_pal_canvas/sp_letter_spacing/sp_letter_spacing.png
vendored
Normal file
After Width: | Height: | Size: 5.1 KiB |
BIN
tests/testdata/control_images/expected_pal_canvas/sp_letter_spacing/sp_letter_spacing_mask.png
vendored
Normal file
After Width: | Height: | Size: 1.8 KiB |
BIN
tests/testdata/control_images/expected_pal_canvas/sp_word_spacing/sp_word_spacing.png
vendored
Normal file
After Width: | Height: | Size: 5.2 KiB |
BIN
tests/testdata/control_images/expected_pal_canvas/sp_word_spacing/sp_word_spacing_mask.png
vendored
Normal file
After Width: | Height: | Size: 1.8 KiB |
BIN
tests/testdata/control_images/expected_pal_composer/sp_img_letter_spacing/sp_img_letter_spacing.png
vendored
Normal file
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 1.8 KiB |
BIN
tests/testdata/control_images/expected_pal_composer/sp_img_word_spacing/sp_img_word_spacing.png
vendored
Normal file
After Width: | Height: | Size: 5.2 KiB |
BIN
tests/testdata/control_images/expected_pal_composer/sp_img_word_spacing/sp_img_word_spacing_mask.png
vendored
Normal file
After Width: | Height: | Size: 1.8 KiB |
BIN
tests/testdata/control_images/expected_pal_composer/sp_pdf_letter_spacing/sp_pdf_letter_spacing.png
vendored
Normal file
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 1.8 KiB |
BIN
tests/testdata/control_images/expected_pal_composer/sp_pdf_word_spacing/sp_pdf_word_spacing.png
vendored
Normal file
After Width: | Height: | Size: 5.2 KiB |
BIN
tests/testdata/control_images/expected_pal_composer/sp_pdf_word_spacing/sp_pdf_word_spacing_mask.png
vendored
Normal file
After Width: | Height: | Size: 1.9 KiB |
BIN
tests/testdata/control_images/expected_pal_composer/sp_svg_letter_spacing/sp_svg_letter_spacing.png
vendored
Normal file
After Width: | Height: | Size: 5.1 KiB |
After Width: | Height: | Size: 2.6 KiB |
BIN
tests/testdata/control_images/expected_pal_composer/sp_svg_word_spacing/sp_svg_word_spacing.png
vendored
Normal file
After Width: | Height: | Size: 5.2 KiB |
BIN
tests/testdata/control_images/expected_pal_composer/sp_svg_word_spacing/sp_svg_word_spacing_mask.png
vendored
Normal file
After Width: | Height: | Size: 1.7 KiB |
BIN
tests/testdata/control_images/expected_pal_server/sp_letter_spacing/sp_letter_spacing.png
vendored
Normal file
After Width: | Height: | Size: 5.1 KiB |
BIN
tests/testdata/control_images/expected_pal_server/sp_letter_spacing/sp_letter_spacing_mask.png
vendored
Normal file
After Width: | Height: | Size: 1.8 KiB |
BIN
tests/testdata/control_images/expected_pal_server/sp_word_spacing/sp_word_spacing.png
vendored
Normal file
After Width: | Height: | Size: 5.2 KiB |
BIN
tests/testdata/control_images/expected_pal_server/sp_word_spacing/sp_word_spacing_mask.png
vendored
Normal file
After Width: | Height: | Size: 1.9 KiB |