#πŸ”’ i need your time pls......everytime i press the proceed button the cart_frame shrinks.

27 messages Β· Page 1 of 1 (latest)

valid depot
#

i couldnt figure out why since four days tried many things ..even AI...now only human as capable as you can save me...code:https://paste.pythondiscord.com/CXWQ ... please help me with my school project. look at the pics i attached notice how it goes up with respect to the order button.

fast agateBOT
#

@valid depot

Python help channel opened

Remember to:

  • Ask your Python question, not if you can ask or if there's an expert who can help.
  • Show a code sample as text (rather than a screenshot) and the error message, if you've got one.
  • Explain what you expect to happen and what actually happens.

:warning: Do not pip install anything that isn't related to your question, especially if asked to over DMs.

valid depot
#

the problem starts after line 445

#

dont spend too much time in upper code

pseudo rapids
#

Should proceed be calling room_for_rest?

valid depot
#

the the problem can be mainly from cart_frame, right_frame, buttonorder , order, proceed.....feel free to look around the code for more

valid depot
#

its 3 am at my place please tell me every possible fix .......im going to sleep and please help me if you see me here with same post 12 hrs later

#

PLEASE

#

πŸ₯Ί

#

im in kinda desperate need

pseudo rapids
#

It looks like the "Order" mode (left screenshot) has either the button aligned to the bottom of the frame, or the empty card autoexpanding to all the free space.
And the "Proceed" mode looks like the cart area has a fixed size and the button is just below it ,instead of being aligned to the bottom of the frame.

I'm not sure where this alignment happens in your code.

#

Since "Cart" is eft aligned in the left shot and centred in the right shot, I suspect you lay out that "Order for" right panel totally differently when there are items in the cart and when there are not?

exotic brook
#

Perhaps there is a way to hide certain frames instead of destroying them constantly?

#

(I'm no expert in tkinter, just offering suggestions)

pseudo rapids
#

IIRC Tk doesn't lend itself to "hidden" widgets. (Versus say an HTML document with a tag with display:none.) You put the widget there or not.

#

I think the OP's layout is just differently specified for the two modes. They want to align their button with the "south" of the enclosing frame, if I'm reading their concern correctly.

#

I suspect that if it were me I'd have the same widgets i.e. just one frame and cart/buttons, but just change the label on the button.

valid depot
pseudo rapids
#

I'm wondering if it is as simple as your buttonorder.grid call on line 583. Try sticking it to the "s" (south) of the frame, maybe sticky="ews".

valid depot
valid depot
#

Also one more question... Why would a button shift a frame... If it's placed in a different row

#

?

austere tiger
#

on this line, try changing corner radius to 0 to match previous mentions

    cart_item_frame = ctk.CTkFrame(cart_frame, fg_color="#404040", corner_radius=10)
fast agateBOT
#
Python help channel closed

This help channel has been closed and it's no longer possible to send messages here. If your question wasn't answered, feel free to create a new post in #1035199133436354600. To maximize your chances of getting a response, check out this guide on asking good questions.