CVS: /anygui/lib/anygui Rectangles.py,1.2,1.3
Magnus Lie Hetland <[email protected]> Wed, 02 Oct 2002 18:09:40 -0700
| Newsgroups | gmane.comp.python.anygui.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/anygui//anygui/lib/anygui
In directory usw-pr-cvs1:/tmp/cvs-serv7508
Modified Files:
Rectangles.py
Log Message:
Fixed mixed case in alias names
Index: Rectangles.py
===================================================================
RCS file: /cvsroot/anygui//anygui/lib/anygui/Rectangles.py,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** Rectangles.py 13 Jul 2002 15:24:04 -0000 1.2
--- Rectangles.py 3 Oct 2002 01:09:38 -0000 1.3
***************
*** 29,32 ****
--- 29,34 ----
# hcenter? What about hmove etc?
+ # FIXME: Rewrite mention of MVC
+
def setBottom(self, bottom):
self.set(y=bottom-self.height)
***************
*** 35,53 ****
return self.y + self.height
! def setBottomleft(self, bottomleft):
! x, y = bottomleft
y -= self.height
self.set(x=x, y=y)
! def getBottomleft(self):
return self.x, self.getBottom()
! def setBottomright(self, bottomright):
! x, y = bottomright
x += self.width
y += self.height
self.set(x=x, y=y)
! def getBottomright(self):
return self.getRight(), self.getBottom()
--- 37,55 ----
return self.y + self.height
! def setBottomLeft(self, bottomLeft):
! x, y = bottomLeft
y -= self.height
self.set(x=x, y=y)
! def getBottomLeft(self):
return self.x, self.getBottom()
! def setBottomRight(self, bottomRight):
! x, y = bottomRight
x += self.width
y += self.height
self.set(x=x, y=y)
! def getBottomRight(self):
return self.getRight(), self.getBottom()
***************
*** 59,76 ****
def getCenter(self):
! return self.getCenterx(), self.getCentery()
! def setCenterx(self, centerx):
! x = centerx - self.width / 2
self.set(x=x)
! def getCenterx(self):
return self.x + self.width / 2
! def setCentery(self, centery):
! x = centery - self.height / 2
self.set(y=y)
! def getCentery(self):
return self.y + self.height / 2
--- 61,78 ----
def getCenter(self):
! return self.getCenterX(), self.getCenterY()
! def setCenterX(self, centerX):
! x = centerX - self.width / 2
self.set(x=x)
! def getCenterX(self):
return self.x + self.width / 2
! def setCenterY(self, centerY):
! y = centerY - self.height / 2
self.set(y=y)
! def getCenterY(self):
return self.y + self.height / 2
***************
*** 88,124 ****
return self.x
! def setMidbottom(self, midbottom):
! x, y = midbottom
x -= self.width / 2
y -= self.height
self.set(x=x, y=y)
! def getMidbottom(self):
! return self.getCenterx(), self.getBottom()
! def setMidleft(self, midleft):
! x, y = midleft
y -= self.height / 2
self.set(x=x, y=y)
! def getMidleft(self):
! return self.x, self.getCentery()
! def setMidright(self, midright):
! x, y = midright
x -= self.width
y -= self.height / 2
self.set(x=x, y=y)
! def getMidright(self):
! return self.getRight(), self.getCentery()
! def setMidtop(self, midtop):
! x, y = midtop
x -= self.width / 2
self.set(x=x, y=y)
! def getMidtop(self):
! return self.getCenterx(), self.y
def setRight(self, right):
--- 90,126 ----
return self.x
! def setMidBottom(self, midBottom):
! x, y = midBottom
x -= self.width / 2
y -= self.height
self.set(x=x, y=y)
! def getMidBottom(self):
! return self.getCenterX(), self.getBottom()
! def setMidLeft(self, midLeft):
! x, y = midLeft
y -= self.height / 2
self.set(x=x, y=y)
! def getMidLeft(self):
! return self.x, self.getCenterY()
! def setMidRight(self, midRight):
! x, y = midRight
x -= self.width
y -= self.height / 2
self.set(x=x, y=y)
! def getMidRight(self):
! return self.getRight(), self.getCenterY()
! def setMidTop(self, midTop):
! x, y = midTop
x -= self.width / 2
self.set(x=x, y=y)
! def getMidTop(self):
! return self.getCenterX(), self.y
def setRight(self, right):
***************
*** 143,162 ****
return self.y
! def setTopleft(self, topleft):
! x, y = topleft
self.set(x=x, y=y)
! def getTopleft(self):
return self.x, self.y
! setPosition = setTopleft
! getPosition = getTopleft
! def setTopright(self, topright):
! x, y = topright
x += self.width
self.set(x=x, y=y)
! def getTopright(self):
return self.x + self.width, self.y
--- 145,164 ----
return self.y
! def setTopLeft(self, topLeft):
! x, y = topLeft
self.set(x=x, y=y)
! def getTopLeft(self):
return self.x, self.y
! setPosition = setTopLeft
! getPosition = getTopLeft
! def setTopRight(self, topRight):
! x, y = topRight
x += self.width
self.set(x=x, y=y)
! def getTopRight(self):
return self.x + self.width, self.y
-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf