replaced the sidebar outline by new components

This commit is contained in:
SallarShayegan
2025-02-25 22:10:16 +01:00
parent 0719a092dc
commit 043c847801

16
main.py
View File

@ -38,7 +38,7 @@ class GuiMain:
for i in range(len(fx_mode_labels)):
x = self.screenW * 2.5 / 19
y = i * self.screenH / 7.3 + 35
y = i * self.screenH / 7.5 + 45
r_x = self.screenW * 0.35 / 19
r_y = (self.screenH-20) / 16
self.fx_mode_buttons.append(LozengeButton(self, fx_mode_labels[i], (x,y), r_x, r_y))
@ -129,14 +129,26 @@ class GuiMain:
for button in self.fx_mode_buttons:
button.display()
for i in range(1,4):
pygame.draw.line(self.screen, color_primary_dark,
(self.fx_mode_buttons[i].radius_x*0.5 + 60, self.fx_mode_buttons[i].y),
(self.fx_mode_buttons[i].x - self.fx_mode_buttons[i].radius_x * 1.5,
self.fx_mode_buttons[i].y))
pygame.draw.circle(self.screen, color_primary,
(40, self.fx_mode_buttons[i].y), 20)
pygame.draw.rect(self.screen, color_primary,
((20, self.fx_mode_buttons[0].y-20),(40, 40)))
"""
pygame.draw.polygon(self.screen, color_primary_dark, [
(12, 12),
(self.screenW * 1.5 / 19 + 12, 12),
(self.screenW * 1.5 / 19 + 12, self.fx_mode_buttons[5].y - 30),
(12, self.screenH/2 - 30)], 2)
"""
pygame.draw.polygon(self.screen, "red", [(0, self.screenH/2), (self.screenW*3 / 19, self.screenH), (0, self.screenH)])
pygame.draw.polygon(self.screen, "white", [(0, self.screenH/2), (self.screenW*3 / 19, self.screenH), (0, self.screenH)])
# flip() the display to put your work on screen
pygame.display.flip()