Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/sugar/graphics
diff options
context:
space:
mode:
authorTomeu Vizoso <tomeu@tomeuvizoso.net>2007-02-21 12:01:20 (GMT)
committer Tomeu Vizoso <tomeu@tomeuvizoso.net>2007-02-21 12:01:20 (GMT)
commit500f979302807c10f8d67635c34e07c91d3150b0 (patch)
treedf96a70899c95b32363fb71f629769ed349e47ab /sugar/graphics
parent6946369ba534be169afa2bde89951a5eef30e163 (diff)
Renamed Button to IconButton.
Diffstat (limited to 'sugar/graphics')
-rw-r--r--sugar/graphics/Makefile.am2
-rw-r--r--sugar/graphics/entry.py4
-rw-r--r--sugar/graphics/iconbutton.py (renamed from sugar/graphics/button.py)4
-rw-r--r--sugar/graphics/label.py1
-rw-r--r--sugar/graphics/optionmenu.py6
5 files changed, 8 insertions, 9 deletions
diff --git a/sugar/graphics/Makefile.am b/sugar/graphics/Makefile.am
index f0ef20d..7032066 100644
--- a/sugar/graphics/Makefile.am
+++ b/sugar/graphics/Makefile.am
@@ -2,7 +2,7 @@ sugardir = $(pythondir)/sugar/graphics
sugar_PYTHON = \
__init__.py \
bubble.py \
- button.py \
+ iconbutton.py \
canvasicon.py \
color.py \
ClipboardBubble.py \
diff --git a/sugar/graphics/entry.py b/sugar/graphics/entry.py
index 490edb2..02e601e 100644
--- a/sugar/graphics/entry.py
+++ b/sugar/graphics/entry.py
@@ -24,7 +24,7 @@ import hippo
from sugar.graphics import units
from sugar.graphics import color
from sugar.graphics import font
-from sugar.graphics.button import Button
+from sugar.graphics.iconbutton import IconButton
from sugar.graphics.roundbox import RoundBox
class Entry(hippo.CanvasBox, hippo.CanvasItem):
@@ -71,7 +71,7 @@ class Entry(hippo.CanvasBox, hippo.CanvasItem):
return gtk.Entry()
def add_button(self, icon_name, action_id):
- button = Button(icon_name=icon_name)
+ button = IconButton(icon_name=icon_name)
button.props.scale = units.SMALL_ICON_SCALE
diff --git a/sugar/graphics/button.py b/sugar/graphics/iconbutton.py
index 28c9f59..80bd52f 100644
--- a/sugar/graphics/button.py
+++ b/sugar/graphics/iconbutton.py
@@ -29,8 +29,8 @@ from sugar import profile
STANDARD_SIZE = 0
SMALL_SIZE = 1
-class Button(hippo.CanvasBox):
- __gtype_name__ = 'Button'
+class IconButton(hippo.CanvasBox):
+ __gtype_name__ = 'SugarIconButton'
__gproperties__ = {
'icon-name' : (str, None, None, None,
diff --git a/sugar/graphics/label.py b/sugar/graphics/label.py
index 61b961e..044c236 100644
--- a/sugar/graphics/label.py
+++ b/sugar/graphics/label.py
@@ -22,7 +22,6 @@ import gtk
import hippo
from sugar.graphics.roundbox import RoundBox
-from sugar.graphics.button import Button
from sugar.graphics import color
from sugar.graphics import font
diff --git a/sugar/graphics/optionmenu.py b/sugar/graphics/optionmenu.py
index 3ee8ac2..2e6e456 100644
--- a/sugar/graphics/optionmenu.py
+++ b/sugar/graphics/optionmenu.py
@@ -24,7 +24,7 @@ import hippo
from sugar.graphics import units
from sugar.graphics.roundbox import RoundBox
-from sugar.graphics import button
+from sugar.graphics import iconbutton
from sugar.graphics import color
from sugar.graphics import font
from sugar.graphics.canvasicon import CanvasIcon
@@ -116,8 +116,8 @@ class OptionMenu(hippo.CanvasBox, hippo.CanvasItem):
self._round_box.append(self._canvas_text, hippo.PACK_EXPAND)
# TODO: Substitute for the right icon.
- arrow = button.Button(icon_name='theme:stock-close')
- arrow.props.size = button.SMALL_SIZE
+ arrow = iconbutton.IconButton(icon_name='theme:stock-close')
+ arrow.props.size = iconbutton.SMALL_SIZE
arrow.props.yalign = hippo.ALIGNMENT_CENTER
arrow.props.xalign = hippo.ALIGNMENT_START
self._round_box.append(arrow)