[pygtk] Add overlay icons example to gtk-demo and pygtk-demo

2014-07-24 Thread Genghis Khan
Hallo,

In order to avoid from using specific icon set(s), which consequently
may cause to inconsistencies in Look & Feel, I suggest to add an
example code to gtk-demo, gtk3-demo and pygtk-demo of overlay icons.

Some software that have overlay icons are:
 Caja, Nautilus and Thunar file manager (GTK+, folder emblem).
 Blueman bluetooth manager (PyGTK, system tray).

See issue at:
http://www.thewildbeast.co.uk/claws-mail/bugzilla/show_bug.cgi?id=3066

Regards,
 --GK

-- 
()  ascii ribbon campaign - against html e-mail
/\  www.asciiribbon.org   - against proprietary attachments
___
pygtk mailing list   pygtk@daa.com.au
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://faq.pygtk.org/

Re: [pygtk] Question concerning to detection of locale direction

2013-06-26 Thread Genghis Khan
As far as I understand, this code is for GTK3.

Can you provide inputs that are of GTK2?

Request is: Recognize direction of currently used GUI. (RTL or LTR)

On Mon, 15 Apr 2013 11:10:14 +0200
Timo  wrote:

> Op 15-04-13 10:38, Genghis Khan schreef:
> > Hello,
> >
> > How is it possible to detect alignment of currently in-use gtk20.mo
> > without directly probing gtk20.mo with msgunfmt for "default:RTL"?
> >
> > I have seen the following but I am not sure if it is applied to
> > PyGTK, and I am also not sure it is relevant.
> > https://developer.gnome.org/gtk3/3.4/GtkEntry.html#gtk-entry-get-alignment
> 
> I'm not really sure what you're asking, but I'm guessing you're 
> searching for the default text direction, right? If not, specify your 
> question.
> 
> This should do it:
> 
> >>> from gi.repository import Gtk
> >>> Gtk.Widget.get_default_direction() == Gtk.TextDirection.LTR
> True
> >>> Gtk.Widget.set_default_direction(Gtk.TextDirection.RTL)
> >>> button = Gtk.Button("Just for testing")
> >>> button.get_direction() == Gtk.TextDirection.RTL
> True
> 
> Timo
> 
> >
> > Regards,
> > --GK.
> >
> 
> ___
> pygtk mailing list pygtk@daa.com.au
> http://www.daa.com.au/mailman/listinfo/pygtk
> Read the PyGTK FAQ: http://faq.pygtk.org/


-- 
Proper English www.reddit.com/r/proper
4 teh lulz... http://email.is-not-s.ms
___
pygtk mailing list   pygtk@daa.com.au
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://faq.pygtk.org/


Re: [pygtk] Question concerning to detection of locale direction

2013-04-15 Thread Genghis Khan
Thank you, Timo, for your respond.

I need to know the direction of the GUI widget.

In this issue, what I am attempting to solve is false direction of
status messages in chat dialog of Gajim (Jabber/XMPP IM Client).


Problem:
Assume you are using a Left-to-right locale (e.g. English, German).
If a status message is of a user with a Right-to-left nickname (e.g.
Arabic) then the status message will be aligned from right direction
instead of left.


Realization string: %s has joined the group chat

LTR nick:
Timo has joined the group chat

RTL nick (look to the right >>):
العربية has joined the group chat

RTL nick + direction_mark (LRM):
‎العربية has joined the group chat


Solution:
* Detect direction/alignment of currently used locale.
* Insert a direction_mark (in accord to locale) before status message.


Relevant file:
https://trac.gajim.org/browser/src/conversation_textview.py?rev=14416

Recent change:
https://trac.gajim.org/changeset/001d4e759427


On Mon, 15 Apr 2013 11:10:14 +0200
Timo  wrote:

> Op 15-04-13 10:38, Genghis Khan schreef:
> > Hello,
> >
> > How is it possible to detect alignment of currently in-use gtk20.mo
> > without directly probing gtk20.mo with msgunfmt for "default:RTL"?
> >
> > I have seen the following but I am not sure if it is applied to
> > PyGTK, and I am also not sure it is relevant.
> > https://developer.gnome.org/gtk3/3.4/GtkEntry.html#gtk-entry-get-alignment
> 
> I'm not really sure what you're asking, but I'm guessing you're 
> searching for the default text direction, right? If not, specify your 
> question.
> 
> This should do it:
> 
> >>> from gi.repository import Gtk
> >>> Gtk.Widget.get_default_direction() == Gtk.TextDirection.LTR
> True
> >>> Gtk.Widget.set_default_direction(Gtk.TextDirection.RTL)
> >>> button = Gtk.Button("Just for testing")
> >>> button.get_direction() == Gtk.TextDirection.RTL
> True
> 
> Timo
> 
> >
> > Regards,
> > --GK.
> >
> 
> ___
> pygtk mailing list pygtk@daa.com.au
> http://www.daa.com.au/mailman/listinfo/pygtk
> Read the PyGTK FAQ: http://faq.pygtk.org/


-- 
Proper English www.reddit.com/r/proper
4 teh lulz... http://email.is-not-s.ms
<>___
pygtk mailing list   pygtk@daa.com.au
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://faq.pygtk.org/

[pygtk] Question concerning to detection of locale direction

2013-04-15 Thread Genghis Khan
Hello,

How is it possible to detect alignment of currently in-use gtk20.mo
without directly probing gtk20.mo with msgunfmt for "default:RTL"?

I have seen the following but I am not sure if it is applied to PyGTK,
and I am also not sure it is relevant.
https://developer.gnome.org/gtk3/3.4/GtkEntry.html#gtk-entry-get-alignment

Regards,
--GK.

-- 
Proper English www.reddit.com/r/proper
4 teh lulz... http://email.is-not-s.ms
___
pygtk mailing list   pygtk@daa.com.au
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://faq.pygtk.org/