Results 1 to 1 of 1
Ok, it's a mess Anyway the question is how to get a nice column of Entry/Label widgets on the left side of the window? Everything I've tried so far leads ...
- 12-07-2007 #1Linux Newbie
- Join Date
- Sep 2005
- Posts
- 140
python+tkinter+canvas
Ok, it's a mess
Anyway the question is how to get a nice column of Entry/Label widgets on the left side of the window? Everything I've tried so far leads to weird spacing. Does this only work vertically?
Code:#!/usr/bin/env python from Tkinter import * import math class Circlemill: def __init__(self, master): frame = Frame(master) frame.pack() self.frame1 = Frame(frame, width=300, height=500) self.frame1.pack(side=LEFT) self.frame14 = Frame(self.frame1, width=250, height=500) self.frame14.grid(row=0, column=0) canvas = Canvas(self.frame1, width=300, height=500) canvas.create_text( 140, 40, text="Progam cuts a rough diamter in steps\ \nuntil full depth is reached. \nFollowed by one finish cut at full depth") canvas.create_text( 140, 330, text="the dashed red line shows the lead-in\ \nto the final cut. Slightly exagerated here :}") canvas.create_oval( 45, 75, 255, 285, dash=(4, 4), fill='white') canvas.create_oval( 70, 100, 230, 260, fill='cyan', outline='cyan') canvas.create_oval( 220, 180, 230, 190, fill='black') canvas.create_arc( 60, 75, 230, 280, style=ARC, dash=(4, 4), outline='red') canvas.create_oval(80, 110, 220, 250, fill='white') canvas.create_text(153,185, text="cyan area is cut \nfirst until\ full \ndepth is reached", fill="purple",font=("Helvectica", "12")) canvas.grid(row=0, column=1) self.l14 = Label(self.frame14, text='please work') self.l14.grid(row=1, column=0) root = Tk() root.title("SandBox") app = Circlemill(root) root.mainloop()WARNING: I may be telling you more than I know !


Reply With Quote