Cartesian editor

-------- Пересылаемое сообщение --------
04.11.09, 17:31, “Konstantin Tokarev” annulen@yandex.ru:

Hi!

04.11.09, 08:33, “David C. Lonie” :

Another ways are to transofm it into fractional
coordinate editor for xstallography, as it was requested recently,
I requested this, and planned to add it myself at some point, but I
probably wouldn’t get to it for a while. So, if you’d like to put it
in, be my guest :slight_smile: If you are going to, I just wanted make you aware
of OpenBabel::OBUnitCell::GetFractionalMatrix()
http://openbabel.org/api/2.2.0/classOpenBabel_1_1OBUnitCell.shtml#2ac2c43b65936f802681d33aff49bc25
which makes the whole operation much easier.

Will it be OK to change old cartesian editor to show fractional coordinates?

I believe Marcus is refering to how the code is indented, not the
output in the widget. We use the KDE conventions for code style:
http://techbase.kde.org/Policies/Kdelibs_Coding_Style

I’ve used style from propextension.cpp. If it’s incorrect, it should be changed too

04.11.09, 08:48, “Marcus D. Hanwell” :

I think it is a great addition, there are a few rough edges but they can
be worked out in master. My time has been very limited these last few
weeks as I began a new job in a new area on 1 October, and to add to
that have a new family (five month old baby).
We also just had our first stable release, and I think everyone is
getting used to that. I think that this editor belongs in master, and we
can work on any remaining issues there. I think we should be very
careful with the 1.0 branch, and most developers should not be too
concerned with it unless there are bugs that need fixing.

It would be nice if new cartesian editor was backported into stable branch after proper testing. It really improves usefullness of Avogadro for computational chemistry


Regards,
Konstantin

-------- Завершение пересылаемого сообщения --------


Regards,
Konstantin

Цветная почта находится здесь: http://mail.yandex.ru/promo/new/colors

Forgot to reply to all…

On Thu, Nov 5, 2009 at 4:38 PM, Konstantin Tokarev annulen@yandex.ru wrote:

Take a look at QApplication::font().pointSize(). Is this what you are
looking for?
http://doc.trolltech.com/4.5/qapplication.html#font
http://doc.trolltech.com/4.5/qfont.html#pointSize

Unfortunately, it doesn’t work. Since font size is default, fontPointSize() returns 0

Did you try the entire QApplication call I mention above? It’s working
here. If I add to my extensions:

#include

qDebug() << "Font size: " << QApplication::font().pointSize();

I get “Font size: 10” in the output. This should return the default
point size unless the default is specified in pixels, in which case
QApplication::font().pixelSize() is needed, along with some
calculations to get from pixels to points.

Dave

qDebug() << "Font size: " << QApplication::font().pointSize();

It works, thank you!


Regards,
Konstantin