Slashdot Mirror


User: josse

josse's activity in the archive.

Stories
0
Comments
2
First seen
Last seen
Profile
(view on slashdot.org)

Comments · 2

  1. Qt does not support all of C++ on Cross-Platform GUI Toolkits (Again)? · · Score: 5, Informative

    I have been using Qt for the last 1.5 years to develop an application for post-processing of segmented (medical) image data as part of my master thesis. The application is available under the GPL at sourceforge

    During development one major disadvantage of Qt has surfaced, and I think it shows that the Trolltech has choosen a terribly wrong solution to a complex problem.

    In order to support their signals-and-slots mechanism (which is an elegant concept, and allows for easy implementation of both the model-observer pattern and the mediator pattern) they have added two new keywords to the language, namely signals and slots. In order to support these you _HAVE_ to run a preprocessor called moc (Meta Object Compiler) for your program to link. But moc does not support templates.

    Mostly we have managed to work around this limitation by having a non-template superclass which declares the signals and slots (luckily slots can be virtual) and then have the template parts in a subclass, but this leads to unnatural class hierarchies.

    Other libraries have managed to support a signals-and-slots mechanism without such an ugly hack. Both Boost.signals and libsic++ implement them. However their syntax is not as nice as Qt's. If C++ really need even more syntax is of course another question :-)

    While not all applications rely upon templates, they have some interesting uses, and if an applications first starts to use them, most classes easily ends up as template classes. See the book Modern C++ Design for "new-school" uses of templates. This could easily be the direction C++ development is headed, and it's a shame Qt will not be able to be a part of it.

  2. Re:In related news.... 4 = 5 on The Poincaré Conjecture has Been Proved · · Score: 1

    The problem with infinity is that you can't use it like a number, because it isn't one. Infinity literally means that there is an infinite number of things, e.g. the set of integers is infinite, meaning you can never list all integers because there is always a successor.


    At the same time there _are_ numbers larger than infinity. The set of intergers is countably infinite, while the set of reals is uncountably infinite. Meaning you can put as many reals as you want between two other reals. No matter how close the two reals you pick are, you still can't count the number of reals between them.

    A countable set is defined as a set where there exist a 1-1 mapping into the set of integers.

    The cardinality (number of members in a set) of N (the set of integers) is called aleph_0. One does not know which aleph that corresponds to the cardinality of reals. One does not think it is aleph_1

    Read the excellent book "The Mystery of the Aleph" by Amir D. Aczel for more information about an exciting branch of mathematics.
    --
    josse