Re: [Development] Question about QCoreApplicationData::*_libpaths

2016-01-21 Thread Milian Wolff
On Donnerstag, 21. Januar 2016 05:44:05 CET Kevin Kofler wrote: > Bubke Marco wrote: > > So you optimized the container for growing with allocations. I don't think > > it is the most common case. Having cache misses in traversing the > > container can be much worse and is much harder to fix than a

Re: [Development] Binding evaluation during ListView delegate remove animation

2016-01-21 Thread Stephen Kelly
On 21/01/16 00:45, Andrew den Exter wrote: On Thu, Jan 21, 2016 at 2:11 AM, Stephen Kelly > wrote: And there are the obvious runtime costs to building and maintaining a cache that is of little or no use to most people

Re: [Development] What kind of airplane we want to build?

2016-01-21 Thread André Somers
Op 21/01/2016 om 10:02 schreef Marc Mutz: I'm not saying we don't need new API should we replace QThread with std::thead. I'm saying that all the hard, impressive, work is already done. It seems to be mostly a question of API now. Sorry, but I think API design _is_ the hard work. Not the part

Re: [Development] What kind of airplane we want to build?

2016-01-21 Thread Marc Mutz
On Thursday 21 January 2016 09:14:58 André Somers wrote: > Op 21/01/2016 om 10:02 schreef Marc Mutz: > > I'm not saying we don't need new API should we replace QThread with > > std::thead. I'm saying that all the hard, impressive, work is already > > done. It seems to be mostly a question of API

Re: [Development] Question about QCoreApplicationData::*_libpaths

2016-01-21 Thread Marc Mutz
On Thursday 21 January 2016 07:59:18 Mathias Hasselmann wrote: > Am 21.01.2016 um 08:00 schrieb Marc Mutz: > > On Thursday 21 January 2016 05:24:35 Kevin Kofler wrote: > >> Marc Mutz wrote: > >>> On Wednesday 20 January 2016 22:50:43 Kevin Kofler wrote: > All these are horrible and

Re: [Development] Question about QCoreApplicationData::*_libpaths

2016-01-21 Thread Marc Mutz
On Thursday 21 January 2016 05:33:51 Kevin Kofler wrote: > Marc Mutz wrote: > > You can lock a mutex in the function and unlock it in the shared_ptr's > > deleter. > > How can that possibly be faster than atomic reference counting? You have > the same cross-thread dependence plus a potential wait

Re: [Development] Heads up for Qt Bug Report & Code Review users

2016-01-21 Thread Jokiniva Jukka
Maintenance break is over and systems are back online. Use your unified Qt Account credentials to login from now on. If you find bugs, please report them here: https://bugreports.qt.io/browse/QTJIRA -Jukka From: Jokiniva Jukka

Re: [Development] Question about QCoreApplicationData::*_libpaths

2016-01-21 Thread Marc Mutz
On Thursday 21 January 2016 05:49:55 Kevin Kofler wrote: > Marc Mutz wrote: > > best of three runs, core i7-2720QM, GCC 5.3 > > What OS and C library are you running those benchmarks on? The performance > of realloc is vastly different between operating systems, so this is > important

Re: [Development] What kind of airplane we want to build?

2016-01-21 Thread Bubke Marco
On January 21, 2016 1:28:58 AM Marc Mutz wrote: > On Wednesday 20 January 2016 21:52:49 Thiago Macieira wrote: >> On Wednesday 20 January 2016 21:08:07 Pau Garcia i Quiles wrote: >> > Replacing QThread with std::thread? Please don't. >> >> Unlike the containers or even

Re: [Development] What kind of airplane we want to build?

2016-01-21 Thread André Somers
Op 21/01/2016 om 11:17 schreef Marc Mutz: On Thursday 21 January 2016 09:14:58 André Somers wrote: Op 21/01/2016 om 10:02 schreef Marc Mutz: I'm not saying we don't need new API should we replace QThread with std::thead. I'm saying that all the hard, impressive, work is already done. It

Re: [Development] Binding evaluation during ListView delegate remove animation

2016-01-21 Thread Giuseppe D'Angelo
On Thu, Jan 21, 2016 at 4:43 PM, André Somers wrote: > I was wondering: how do you know when to drop the cached data again? When the corresponding delegate gets evicted by ListView at the end of the removal animation. Cheers, -- Giuseppe D'Angelo

Re: [Development] Binding evaluation during ListView delegate remove animation

2016-01-21 Thread André Somers
Op 21/01/2016 om 16:13 schreef Stephen Kelly: On 21/01/16 14:56, Stephen Kelly wrote: * Something else As Andre wrote, 'something else' could be 'populate a "memory structure" for all roles for the specific rows being removed in response to rowsAboutToBeRemoved'. I would not use all

Re: [Development] Binding evaluation during ListView delegate remove animation

2016-01-21 Thread Stephen Kelly
On 21/01/16 14:56, Stephen Kelly wrote: * Something else As Andre wrote, 'something else' could be 'populate a "memory structure" for all roles for the specific rows being removed in response to rowsAboutToBeRemoved'. -- Ableton AG, Schoenhauser Allee 6-7, 10119 Berlin, Germany

Re: [Development] Question about QCoreApplicationData::*_libpaths

2016-01-21 Thread Bo Thorsen
Den 21-01-2016 kl. 14:15 skrev Milian Wolff: On Donnerstag, 21. Januar 2016 05:44:05 CET Kevin Kofler wrote: I consider reserve() to be a technical detail and a micro-optimization I really should not have to bother with in 99+% of the cases. That's how it should be. This is very wrong. In

Re: [Development] Binding evaluation during ListView delegate remove animation

2016-01-21 Thread Stephen Kelly
On 21/01/16 08:12, André Somers wrote: Actually, I think it would not need to be quite as bad. For starters, you really only need to cache the actual items being removed. At the moment the model emits the AboutToBeRemoved signal, the data should still be there in any well-behaved model,

Re: [Development] Qt 5.6.0 header diff

2016-01-21 Thread Frederik Gladhorn
Hello, this is an update, the final header diff. Since we all agree that email is not the perfect medium for the header review (I see some open questions in the old thread), I'd thought I'll go for an attempt at pushing the diffs to gerrit. I'm not quite satisfied with the outcome, ideas for

Re: [Development] Question about QCoreApplicationData::*_libpaths

2016-01-21 Thread Bubke Marco
On January 21, 2016 3:51:09 PM Bo Thorsen wrote: > Den 21-01-2016 kl. 14:15 skrev Milian Wolff: >> On Donnerstag, 21. Januar 2016 05:44:05 CET Kevin Kofler wrote: >>> I consider reserve() to be a technical detail and a micro-optimization I >>> really should not have to bother

Re: [Development] Question about QCoreApplicationData::*_libpaths

2016-01-21 Thread Matthew Woehlke
On 2016-01-20 23:27, Kevin Kofler wrote: > Thiago Macieira wrote: >> The copy constructor is called once, then the move constructor. If >> value_type's move constructor is not noexcept, then it may throw after the >> container resized. > > Throwing an exception in a move constructor is really,

Re: [Development] Question about QCoreApplicationData::*_libpaths

2016-01-21 Thread Matthew Woehlke
On 2016-01-20 17:43, Giuseppe D'Angelo wrote: > This poses further questions down the line, such as whether it's "ok" > having an index API based on signed integers. (It is for convenience, it > is not for correctness, but I guess that's all the topic here, isn't it? > :)) As Thiago noted, C++

Re: [Development] Question about QCoreApplicationData::*_libpaths

2016-01-21 Thread Matthew Woehlke
On 2016-01-20 23:44, Kevin Kofler wrote: > Almost all my containers grow with allocations. How should I know in advance > how much memory to reserve? It'd just waste an arbitrary amount of memory > and then still end up reallocating because it'll inevitably be exceeded at > some point.

[Development] QFont::setFamily("monospace") on OS X

2016-01-21 Thread René J . V . Bertin
Hello, Not sure if this is the best place to ask: I think QFont::setFamily("monospace") should allow to obtain an appropriate monospace font on all platforms. It does with the XCB QPA , giving me the Consolas font (ideally it should return the fixed-width font that goes with the active

Re: [Development] Question about QCoreApplicationData::*_libpaths

2016-01-21 Thread Milian Wolff
On Donnerstag, 21. Januar 2016 07:25:21 CET André Somers wrote: > Op 21/01/2016 om 05:35 schreef Thiago Macieira: > > On Thursday 21 January 2016 05:27:50 Kevin Kofler wrote: > >> Thiago Macieira wrote: > >>> The copy constructor is called once, then the move constructor. If > >>> value_type's

Re: [Development] Binding evaluation during ListView delegate remove animation

2016-01-21 Thread André Somers
Op 21/01/2016 om 16:55 schreef Giuseppe D'Angelo: On Thu, Jan 21, 2016 at 4:43 PM, André Somers wrote: I was wondering: how do you know when to drop the cached data again? When the corresponding delegate gets evicted by ListView at the end of the removal animation.

Re: [Development] What kind of airplane we want to build?

2016-01-21 Thread Thiago Macieira
On Thursday 21 January 2016 10:02:41 Marc Mutz wrote: > Having had to teach this stuff to customers when this came out in Qt 4, I > can tell you this distinction will not register with most Qt-newbies. > Allowing such ease of wrong API use is against my reading Qt's own design > principles ("make

Re: [Development] QFont::setFamily("monospace") on OS X

2016-01-21 Thread René J . V . Bertin
On Thursday January 21 2016 20:31:52 Liang Qi wrote: Possibly, but that function takes a font type, not a family name. So it's probably the culprit only if it is called with the FixedFont type after someone did setFamily("monospace"). R. > Perhaps QPlatformTheme::font() is related. > >

Re: [Development] Heads up for Qt Bug Report & Code Review users

2016-01-21 Thread Thiago Macieira
On Thursday 21 January 2016 10:27:06 Jokiniva Jukka wrote: > Maintenance break is over and systems are back online. Use your unified Qt > Account credentials to login from now on. > > If you find bugs, please report them here: > https://bugreports.qt.io/browse/QTJIRA Looks like I will soon[*]

Re: [Development] Question about QCoreApplicationData::*_libpaths

2016-01-21 Thread Kevin Kofler
Marc Mutz wrote: > I was replying to Kevin. QModelIndex exactly fits his complaints about > const-&: > > It's a reference used in interfaces. As soon as you store it, though, it > may become stale at the next opportunity (like when calling a virtual > function). You're supposed to store them in

Re: [Development] Question about QCoreApplicationData::*_libpaths

2016-01-21 Thread Kevin Kofler
Marc Mutz wrote: > But the discussions about move ctors that throw aren't even about > bad_alloc. They are about assertion exceptions. How is a move constructor an appropriate place for a sanity check? The only way the moved object can be invalid is if the original object was already invalid.

Re: [Development] Question about QCoreApplicationData::*_libpaths

2016-01-21 Thread Andre Somers
On 21-1-2016 21:09, Milian Wolff wrote: On Donnerstag, 21. Januar 2016 07:25:21 CET André Somers wrote: Op 21/01/2016 om 05:35 schreef Thiago Macieira: On Thursday 21 January 2016 05:27:50 Kevin Kofler wrote: Thiago Macieira wrote: The copy constructor is called once, then the move

Re: [Development] What kind of airplane we want to build?

2016-01-21 Thread Simon Everts
2016-01-20 15:48 GMT+01:00 Ziller Eike : > > > But Qt is available in D and Python, too, so ... > > why do they use C++ if they so hate it? > > Maybe they don’t hate it, but still wished it had a less verbose API if you > don’t need the verbosity. Understanding why

Re: [Development] Question about QCoreApplicationData::*_libpaths

2016-01-21 Thread Marc Mutz
On Thursday 21 January 2016 22:44:02 Andre Somers wrote: > On 21-1-2016 21:09, Milian Wolff wrote: > > On Donnerstag, 21. Januar 2016 07:25:21 CET André Somers wrote: > >> Op 21/01/2016 om 05:35 schreef Thiago Macieira: > >>> On Thursday 21 January 2016 05:27:50 Kevin Kofler wrote: > Thiago

Re: [Development] Question about QCoreApplicationData::*_libpaths

2016-01-21 Thread Milian Wolff
On Donnerstag, 21. Januar 2016 22:44:02 CET Andre Somers wrote: > On 21-1-2016 21:09, Milian Wolff wrote: > > On Donnerstag, 21. Januar 2016 07:25:21 CET André Somers wrote: > >> Op 21/01/2016 om 05:35 schreef Thiago Macieira: > >>> On Thursday 21 January 2016 05:27:50 Kevin Kofler wrote: >

Re: [Development] Question about QCoreApplicationData::*_libpaths

2016-01-21 Thread Kevin Kofler
Marc Mutz wrote: > Ivan was talking about thread-safe classes. You need to lock a mutex to > take the copy. Returning a QMap instead of a std::shared_ptr would be perfectly thread-safe there. The atomic reference counting would ensure that any thread that wants to write to the data that another

[Development] A simple analysis of apps using qtbase's private headers

2016-01-21 Thread Lisandro Damián Nicanor Pérez Meyer
I did a **very** simple analysis of apps packaged in Debian using qtbase's private headers. My main concern was to see if we (Debian) can avoid having to rebuild them every time we push a new version of Qt to our archive. What I've found seemed interesting so I decided to share it here. The

Re: [Development] Qt 5.6.0 header diff

2016-01-21 Thread Thiago Macieira
On Thursday 21 January 2016 16:56:56 Frederik Gladhorn wrote: > Hello, > > this is an update, the final header diff. > Since we all agree that email is not the perfect medium for the header > review (I see some open questions in the old thread), I'd thought I'll go > for an attempt at pushing the

Re: [Development] Heads up for Qt Bug Report & Code Review users

2016-01-21 Thread Jokiniva Jukka
Unfortunately I can¹t think any optimal solution for this. Having two emails means that you need to have two Qt Accounts. I would resolve it by running Jira with my personal account on different browser. Not optimal, but works. ‹Jukka On 22/01/16 01:50, "Development on behalf of Thiago

Re: [Development] Heads up for Qt Bug Report & Code Review users

2016-01-21 Thread Thiago Macieira
On Friday 22 January 2016 07:12:19 Jokiniva Jukka wrote: > Unfortunately I can¹t think any optimal solution for this. > Having two emails means that you need to have two Qt Accounts. > > I would resolve it by running Jira with my personal account on different > browser. > Not optimal, but works.

Re: [Development] QFont::setFamily("monospace") on OS X

2016-01-21 Thread Liang Qi
Perhaps QPlatformTheme::font() is related. https://github.com/qtproject/qtbase/blob/5.6/src/gui/kernel/qplatformtheme.h Regards, Liang On 21 January 2016 at 18:29, René J.V. wrote: > Hello, > > Not sure if this is the best place to ask: > I think