IsidoreSong commited on
Commit
ba746dd
·
verified ·
1 Parent(s): f799a80

Update src/pyscripts/img_process.py

Browse files
Files changed (1) hide show
  1. src/pyscripts/img_process.py +3 -3
src/pyscripts/img_process.py CHANGED
@@ -544,12 +544,12 @@ def write_person_line(background, person, H_PADDING_RATION, start_y, photo_size_
544
  round_photo = write_round_photo(background, person, H_PADDING_RATION * bg_width + radius, start_y + radius, radius)
545
  pioneer_part_width += round_photo.size[1]
546
 
547
- title = person["title"].split("\n")
548
 
549
  name_padding = 50 * scale
550
  title_padding = 20 * scale
551
 
552
- people_text_y = start_y + (2 * radius - font_size - name_padding - title_font_size * scale * len(person["title"])) // 2
553
  conference_rundown_people_name, background, next_height = write_text(
554
  text,
555
  font_path,
@@ -564,7 +564,7 @@ def write_person_line(background, person, H_PADDING_RATION, start_y, photo_size_
564
  font_size = title_font_size * scale
565
  font_path = font_path_notosansM
566
  # pioneer_part_width = H_PADDING_RATION * bg_width + round_photo.size[1] + font_size
567
- for i, text in enumerate(title):
568
  conference_rundown_people_title, background, next_height = write_text(
569
  text,
570
  font_path,
 
544
  round_photo = write_round_photo(background, person, H_PADDING_RATION * bg_width + radius, start_y + radius, radius)
545
  pioneer_part_width += round_photo.size[1]
546
 
547
+ titles = person["title"].split("\n")
548
 
549
  name_padding = 50 * scale
550
  title_padding = 20 * scale
551
 
552
+ people_text_y = start_y + (2 * radius - font_size - name_padding - title_font_size * scale * len(titles)) // 2
553
  conference_rundown_people_name, background, next_height = write_text(
554
  text,
555
  font_path,
 
564
  font_size = title_font_size * scale
565
  font_path = font_path_notosansM
566
  # pioneer_part_width = H_PADDING_RATION * bg_width + round_photo.size[1] + font_size
567
+ for i, text in enumerate(titles):
568
  conference_rundown_people_title, background, next_height = write_text(
569
  text,
570
  font_path,