| Submitter | Dongxiao Xu |
|---|---|
| Date | April 12, 2012, 3:46 p.m. |
| Message ID | <d64dca4f0fcdcea2641e4751bbd300b7d2aa49e1.1334245432.git.dongxiao.xu@intel.com> |
| Download | mbox | patch |
| Permalink | /patch/25697/ |
| State | New |
| Headers | show |
Comments
On Thu, 2012-04-12 at 23:46 +0800, Dongxiao Xu wrote: > Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com> > --- > lib/bb/ui/crumbs/hig.py | 2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) > > diff --git a/lib/bb/ui/crumbs/hig.py b/lib/bb/ui/crumbs/hig.py > index 5cc8a59..b0cfcaf 100644 > --- a/lib/bb/ui/crumbs/hig.py > +++ b/lib/bb/ui/crumbs/hig.py > @@ -392,7 +392,7 @@ class AdvancedSettingDialog (CrumbsDialog): > j = 1 > for image_type in self.image_types: > self.image_types_checkbuttons[image_type] = gtk.CheckButton(image_type) > - self.image_types_checkbuttons[image_type].set_tooltip_text("Build an %s image" % image_type) > + self.image_types_checkbuttons[image_type].set_tooltip_text("Build a(n) %s image" % image_type) > table.attach(self.image_types_checkbuttons[image_type], j, j + 4, i, i + 1) > if image_type in self.configuration.image_fstypes.split(): > self.image_types_checkbuttons[image_type].set_active(True) This change looks rather ugly to me. Whilst we're getting into a minefield of localisation issues, I'd suggest doing: article = "" if image_type.startswith(["a", "e", "i", "o", "h"]): article = "n" self.image_types_checkbuttons[image_type].set_tooltip_text("Build a%s %s image" % (article, image_type)) Whilst this isn't perfect, it should cover our common image types well enough. Cheers, Richard
Patch
diff --git a/lib/bb/ui/crumbs/hig.py b/lib/bb/ui/crumbs/hig.py index 5cc8a59..b0cfcaf 100644 --- a/lib/bb/ui/crumbs/hig.py +++ b/lib/bb/ui/crumbs/hig.py @@ -392,7 +392,7 @@ class AdvancedSettingDialog (CrumbsDialog): j = 1 for image_type in self.image_types: self.image_types_checkbuttons[image_type] = gtk.CheckButton(image_type) - self.image_types_checkbuttons[image_type].set_tooltip_text("Build an %s image" % image_type) + self.image_types_checkbuttons[image_type].set_tooltip_text("Build a(n) %s image" % image_type) table.attach(self.image_types_checkbuttons[image_type], j, j + 4, i, i + 1) if image_type in self.configuration.image_fstypes.split(): self.image_types_checkbuttons[image_type].set_active(True)
Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com> --- lib/bb/ui/crumbs/hig.py | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)