Skip to content

Commit

Permalink
Fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
qjasn committed Jan 27, 2024
1 parent ccf2f88 commit e627435
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 10 deletions.
19 changes: 14 additions & 5 deletions .idea/workspace.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 2 additions & 3 deletions ui/equation_ui.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ def create_ui(self, element, _list):
height=self.max_height,
)
], scroll=ScrollMode.AUTO,
width=(((self.page.width - 100) / 7) * 1.8 - 35) if self.page.width > 550 else (
width=(((self.page.width - 100) / 7) * 1.8 - 35) if self.page.width > 550 else (
self.page.width - 55)
)
], top=5
Expand All @@ -101,9 +101,8 @@ def create_ui(self, element, _list):

)
], width=(((self.page.width - 100) / 7) * 1.8) if self.page.width > 550 else self.page.width,
height=50
)
],
height=50
height=(self.latex_image[1] + self.max_height) + 45
)
return self.ui
3 changes: 1 addition & 2 deletions ui/function_ui.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,10 @@ def on_change(self, e):
def on_click(self, _list=None, element=None):
# 该函数在点击 删除 时调用
UString.lists.remove(_list) # 从lists删除对应的结构化函数
print(UString.a_e)
UString.draw_class[_list["name"]].delete() # 清除函数图像
UString.a_e.remove(_list["name"]) # 删除存在的函数名称
UString.draw_class.pop(_list["name"])
element.content.controls.remove(self.ui) # 从页面删除此元素
UString.draw_class[_list["name"]].delete() # 清除函数图像
UString.matplot_chart.update_draw() # 更新UI
self.page.update()

Expand Down

0 comments on commit e627435

Please sign in to comment.