zdxpan commited on
Commit
933d1b0
1 Parent(s): 0f56371

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +16 -16
app.py CHANGED
@@ -332,26 +332,26 @@ with gr.Blocks() as demo:
332
  # movie_file = gr.Video(exam_video,label="movie")
333
  with gr.Column():
334
  # -- 输入背景图底图 作为画布 --
335
- input_image = gr.Image(background_img, label = "背景图, input",interactive=True)
336
- title_x = gr.Slider(1, WIDTH, label = "标题左右移动", value=60, step = 5)
337
- title_y = gr.Slider(1, HEIGHT, label = "标题上下移动", value=320, step = 5)
338
  font_title = gr.Dropdown(choices = font_list, label = "标题字体",
339
- value = "fonts/特创易新恒LOGO美黑.ttf")
340
- sz1 = gr.Slider(1, 100, label = "标题大小", value=80, step = 5)
341
- color1 = gr.Textbox("blue", label = "标题颜色")
342
- bac_color = gr.Textbox("blue", label = "文本框颜色 空不设置文本框")
343
 
344
  with gr.Column():
345
  # -- 子标题
346
- font_subtt = gr.Dropdown(choices = font_list, label = "子标题字体", value = "fonts/吉页颉润体简.ttf")
347
- sz2 = gr.Slider(1, 100, label = "subTitleSZ", value=55, step = 5)
348
- subtt_x = gr.Slider(1, WIDTH, label = "子标题左右-->", value=80, step = 5)
349
- subtt_y = gr.Slider(1, HEIGHT, label = "子标题 上下 ^ v", value=780, step = 5)
350
- color2 = gr.Textbox("#007000", label = "子标题颜色")
351
- font_txt = gr.Dropdown(choices = font_list, label = "文本字体", value = "fonts/simsun.ttc")
352
- sz3 = gr.Slider(1, 100, label = "wordSize", value=40, step = 5)
353
- txt_x = gr.Slider(1, WIDTH, label = "内容位置_x", value=20, step = 5)
354
- color3 = gr.Textbox("#101010", label = "文字颜色")
355
 
356
  with gr.Row():
357
  with gr.Column(): # ----按钮控件------
 
332
  # movie_file = gr.Video(exam_video,label="movie")
333
  with gr.Column():
334
  # -- 输入背景图底图 作为画布 --
335
+ input_image = gr.Image(input_image_, label = "背景图, input",interactive=True)
336
+ title_x = gr.Slider(1, WIDTH, label = "标题左右移动", value=title_x_, step = 5)
337
+ title_y = gr.Slider(1, HEIGHT, label = "标题上下移动", value=title_y_, step = 5)
338
  font_title = gr.Dropdown(choices = font_list, label = "标题字体",
339
+ value = font_title_)
340
+ sz1 = gr.Slider(1, 100, label = "标题大小", value=sz1_, step = 5)
341
+ color1 = gr.Textbox(color1_, label = "标题颜色")
342
+ bac_color = gr.Textbox(bac_color_, label = "文本框颜色 空不设置文本框")
343
 
344
  with gr.Column():
345
  # -- 子标题
346
+ font_subtt = gr.Dropdown(choices = font_list, label = "子标题字体", value = font_subtt_)
347
+ sz2 = gr.Slider(1, 100, label = "subTitleSZ", value=sz2_, step = 5)
348
+ subtt_x = gr.Slider(1, WIDTH, label = "子标题左右-->", value=subtt_x_, step = 5)
349
+ subtt_y = gr.Slider(1, HEIGHT, label = "子标题 上下 ^ v", value=subtt_y_, step = 5)
350
+ color2 = gr.Textbox(color2_, label = "子标题颜色")
351
+ font_txt = gr.Dropdown(choices = font_list, label = "文本字体", value = font_txt_)
352
+ sz3 = gr.Slider(1, 100, label = "wordSize", value=sz3_, step = 5)
353
+ txt_x = gr.Slider(1, WIDTH, label = "内容位置_x", value=txt_x_, step = 5)
354
+ color3 = gr.Textbox(color3_, label = "文字颜色")
355
 
356
  with gr.Row():
357
  with gr.Column(): # ----按钮控件------