Re: [Interest] famous issue : setMouseTracking

2016-03-04 Thread Nicolas Jäger
hi Nye,

> > Initially I just set several widget with setMouseTracking but it didn't  
> worked.
> 
> Well, I'd never had any problem with mouse tracking, but you may have
> stumbled on a bug or a platform incompatibility, however remote that
> possibility might be. Unfortunately, I haven't any more suggestions to
> provide, except to maybe try and trace the problem in your code, and if
> it's indeed a bug to file a report.
> 
> Kind regards.
> 
yes our project is kind unusualy compiled, we compiling with mingw on linux for 
windows (there is
good reasons to do it that way).
I will try to found some solution or to live with that issue...

Regards,
Nicolas.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] scaling QRect inside a QWidget

2016-03-04 Thread Nicolas Jäger
I solved this issue, by some different way I was thinking yesterday.
Thx Nye.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Regarding QtreeWidget

2016-03-04 Thread Tony Rietwyk
Hi Roshni, 

 

It depends on the number of columns, and whether the data is static or dynamic. 
 Even then 500 nodes doesn't sound much, so I would just use QTreeWidget for 
now.  

 

Hope that helps, 

 

Tony

 

 

From: Interest [mailto:interest-bounces+tony=rightsoft.com...@qt-project.org] 
On Behalf Of Roshni Lalwani
Sent: Friday, 4 March 2016 7:06 PM
To: interest@qt-project.org
Subject: [Interest] Regarding QtreeWidget

 

I have application in which I am planning to use a QtreeWidget . The maxinum 
number of elements in the treeWidget can go uptp 500 . COuld you let me how 
will be performance of using QtreeWidget for 500 elements . Will it lead to 
some performance degradation

 

Regards

Roshni

___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Android services

2016-03-04 Thread m...@rpzdesign.com
Why don't you create a skeleton test app and share with the group the 
source code.


I sent you a reply message yesterday suggesting the Android Job API.

You might find sweeter fruit using that.

md


On 3/4/2016 4:46 PM, Jason H wrote:

So I am trying to implement a background service and it's not going very well. 
The service is being used to upload files when the UI is suspended.

My usage differs from the http://www.kdab.com/qt-android-episode-7/ tutorial in 
a number of ways.

1. I have a Qt App
2. I have a subclassed QtActivity
3. I have a subclassed IntentService
4. The intent service calls the native statics functions.
5. I've added  to the manifest, and spec'd MyActivity as the activity.


6. MyActivity::onCreate calls:
 Intent serviceIntent = new Intent(this, MyUploadService.class);
 startService(serviceIntent);

And that's where it stops.

In my MyUploadService,
1. None of the below gets logged:
 @Override
 public MyUploadService() {
 super("MyUploadService");
 java.lang.System.out.println(this.getClass().toString() + " 
Initialized");
 }

 @Override
 public void onCreate() {
 java.lang.System.out.println(this.getClass().toString() + " Created");
 }

 @Override
 public void onHandleIntent(Intent workIntent) {
 java.lang.System.out.println(this.getClass().toString() + " 
onHandleIntent");
 ...
 }

Once the service is started, it is occasionally sent messages for work to do. 
But it doesn't get that far.


Help?

___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest



___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


[Interest] Android services

2016-03-04 Thread Jason H
So I am trying to implement a background service and it's not going very well. 
The service is being used to upload files when the UI is suspended. 

My usage differs from the http://www.kdab.com/qt-android-episode-7/ tutorial in 
a number of ways.

1. I have a Qt App
2. I have a subclassed QtActivity
3. I have a subclassed IntentService 
4. The intent service calls the native statics functions.
5. I've added  to the manifest, and spec'd MyActivity as the activity.


6. MyActivity::onCreate calls:
Intent serviceIntent = new Intent(this, MyUploadService.class);
startService(serviceIntent);

And that's where it stops.

In my MyUploadService, 
1. None of the below gets logged:
@Override
public MyUploadService() {
super("MyUploadService");
java.lang.System.out.println(this.getClass().toString() + " 
Initialized");
}

@Override
public void onCreate() {
java.lang.System.out.println(this.getClass().toString() + " Created");
}

@Override
public void onHandleIntent(Intent workIntent) {
java.lang.System.out.println(this.getClass().toString() + " 
onHandleIntent");
...
}

Once the service is started, it is occasionally sent messages for work to do. 
But it doesn't get that far.


Help?

___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] famous issue : setMouseTracking

2016-03-04 Thread Nye
> Initially I just set several widget with setMouseTracking but it didn't
worked.

Well, I'd never had any problem with mouse tracking, but you may have
stumbled on a bug or a platform incompatibility, however remote that
possibility might be. Unfortunately, I haven't any more suggestions to
provide, except to maybe try and trace the problem in your code, and if
it's indeed a bug to file a report.

Kind regards.

On Fri, Mar 4, 2016 at 2:59 PM, Nicolas Jäger 
wrote:

> hi,
>
> > > if some widget has the setMouseTracking set to true, the event
> > mouseMoveEvent is detected only when a clicked is perfomed.
> >
> > This doesn't sound right, enabling the mouse tracking causes mouse move
> > events to be dispatched to the widget without the need to have a mouse
> > click (provided the mouse is hovering over the widget, if not, mouse
> > tracking doesn't do you any good).
> yes it's doesn't sound right,that's why I try to figure what's going on.
> You can easily find some
> topics about that problem on internet.
>
> >
> > >  I set the SetMouseTracking to true when the mouse enters the widget,
> and
> > I set it to false when the mouse leave the widget. The reason I do that,
> I
> > read somewhere on internet (I didn't kept the link sry) that only one
> > widget at a time can truly have  settled to true. and I
> > want to use it for several widgets.
> >
> > No need to do that. Just enable the mouse tracking for whichever widget
> you
> > want to receive the mouse move events. I believe you're confusing the
> mouse
> > tracking with grabbing the mouse, which is exclusive.
>
> Initially I just set several widget with setMouseTracking but it didn't
> worked. No, I'm not
> confusing between tracking and grabbing. I have no use of grabing.
>
> Regards,
> Nicolas
> ___
> Interest mailing list
> Interest@qt-project.org
> http://lists.qt-project.org/mailman/listinfo/interest
>
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] [OS X] maintaining a list of own WIds

2016-03-04 Thread John Weeks

> On Mar 4, 2016, at 11:24 AM, René J. V. Bertin  wrote:
> 
> Indeed. But it seems it *is* possible to be notified when the widget 
> (finally) 
> does become visible using something like

Which is exactly what we do because we need to know *before* a window is 
minimized:

 void IgorNormalWindow::showEvent(QShowEvent *event) {
QWidget::showEvent(event);
emit windowVisibilityChanged(this, true);
TellIgorWindowStatus(this, WINDOW_STATUS_DID_SHOW, 0);

#ifdef MACIGOR
if (!igorNSWindowNotifier)
{
if (!IgorApp()->IsMDI())
{
igorNSWindowNotifier = 
CreateMinimizeNotification(reinterpret_cast(effectiveWinId()), 
reinterpret_cast(this));
SetNSWindowParticipatesInCycle(this, false);
}
}
else
{
if (IgorApp()->IsMDI())
{
DeleteIgorCocoaWindowNotifier(igorNSWindowNotifier);
igorNSWindowNotifier = NULL;
}
}
#endif

}

The CreateMinimizeNotification() function wraps Objective C++ code that 
ultimately does this:

[[NSNotificationCenter defaultCenter]
addObserver:self

selector:@selector(handleMinimizationNotification:)

name:@"NSWindowWillMiniaturizeNotification"
object:cocoaWindow];

 

-John

___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] [OS X] maintaining a list of own WIds

2016-03-04 Thread René J . V . Bertin
John Weeks wrote:


>> That's what I was really asking about: how
>> to get notified each time something is created that has a WId.
> 
> Which is complicated by Qt's insistence on creating the platform-specific
> thing (wID as NSView, HWND, etc.) only when the QWidget becomes visible.

Indeed. But it seems it *is* possible to be notified when the widget (finally) 
does become visible using something like

[[NSNotificationCenter defaultCenter] addObserver:self
selector:@selector(windowChangedOcclusionState:)
name:NSWindowDidChangeOcclusionStateNotification object:nil];

this will give you the NSWindow* instance that just had a change in occlusion 
state (e.g. it was just mapped for the 1st time); chances are good that that 
window's contentView is the QNSView corresponding to a WId.

Cf. https://git.reviewboard.kde.org/r/126291/


R.

___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Regarding QtreeWidget

2016-03-04 Thread william.croc...@analog.com

On 03/04/2016 11:24 AM, André Somers wrote:



Op 04/03/2016 om 13:20 schreef william.croc...@analog.com:

On 03/04/2016 03:06 AM, Roshni Lalwani wrote:

I have application in which I am planning to use a QtreeWidget . The maxinum
number of elements in the treeWidget can go uptp 500 . COuld you let me how will
be performance of using QtreeWidget for 500 elements . Will it lead to some
performance degradation



Use a QTreeView with an underlying model and performance of the tree widget
will no longer be a concern.




I said that performance of "the tree widget" would no longer be a concern.

:-)

If a tree had a large number of node, I would not use a tree widget for the high
time-0, O(N) load time. The beauty of the view/model approach is that the view 
will
only request information on a small number of indexes at any given time and,
correspondingly, the underlying model would only have to service a small number
of indexes at any given time. Especially at time 0.


Nonsense.
It all depends on your implementation of the model then, and writing good tree
models is not trivial. I agree that generally a "real" model is much to be
prefered, but your statement as-is doesn't make much sense to me.

I think the merrits of QTreeWidget (and all the view like Q*Widget classes) is
debatable, but I don't think performance is the major pain point here. I would
recommend to consider using QStandardItemModel with a QTreeView instead if you
like the item-based API that much. Also, consider wrapping it up in your own
model subclass with a sane API that suits your application, instead of filling
and accessing your model from different places in otherwise unrelated code. This
will make it easier to swap out the QStandardItemModel based model for a custom
model later on if needed.

André

___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest




___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Regarding QtreeWidget

2016-03-04 Thread André Somers



Op 04/03/2016 om 13:20 schreef william.croc...@analog.com:

On 03/04/2016 03:06 AM, Roshni Lalwani wrote:
I have application in which I am planning to use a QtreeWidget . The 
maxinum
number of elements in the treeWidget can go uptp 500 . COuld you let 
me how will
be performance of using QtreeWidget for 500 elements . Will it lead 
to some

performance degradation



Use a QTreeView with an underlying model and performance of the tree 
widget

will no longer be a concern.


Nonsense.
It all depends on your implementation of the model then, and writing 
good tree models is not trivial. I agree that generally a "real" model 
is much to be prefered, but your statement as-is doesn't make much sense 
to me.


I think the merrits of QTreeWidget (and all the view like Q*Widget 
classes) is debatable, but I don't think performance is the major pain 
point here. I would recommend to consider using QStandardItemModel with 
a QTreeView instead if you like the item-based API that much. Also, 
consider wrapping it up in your own model subclass with a sane API that 
suits your application, instead of filling and accessing your model from 
different places in otherwise unrelated code. This will make it easier 
to swap out the QStandardItemModel based model for a custom model later 
on if needed.


André

___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Dynamic translations for mobile apps at runtime?

2016-03-04 Thread Jérôme Godbout
Just to be clear, the lupdate did not found the string and skip it, nothing
new is found or updated. The usage after work properly.

On Fri, Mar 4, 2016 at 9:06 AM, Jérôme Godbout  wrote:

> >  "-tr-function-alias qsTr=MySingleton.myqsTr"
> That's what I tried but it didn't work sadly. That would have solve it
> nicely.
>
> On Thu, Mar 3, 2016 at 5:43 PM, Jason H  wrote:
>
>> What if you did "-tr-function-alias qsTr=MySingleton.myqsTr" ?
>>
>> *Sent:* Thursday, March 03, 2016 at 5:31 PM
>> *From:* "Jérôme Godbout" 
>> *To:* "Julien Cugnière" 
>> *Cc:* "interest@qt-project.org" 
>> *Subject:* Re: [Interest] Dynamic translations for mobile apps at
>> runtime?
>> I test it out, it work as long as the function is a direct function
>> access, you can't use module call like
>>
>> MySingleton.myqsTr("My String") // don't work, lupdate does get this one
>> myqsTr("My String") // work
>>
>> Could have put the function into it's own javascript .pragma library and
>> just import it in needed file. Is their a way to declare a global
>> javascript function into the engine with the binding still working? I just
>> don't want to add the function on each file if possible:
>>
>> *function myqsTr(str) { return qsTr(str) + I18n.revaluate; }*
>>
>> I may try to add the function into the RootItem of the QQuickView and
>> hope the context hierarchies will always find it everywhere to see if this
>> work.
>>
>> That's so close to work well...
>>
>>
>>
>> On Thu, Mar 3, 2016 at 3:41 PM, Jérôme Godbout 
>> wrote:
>>>
>>> Nice, I didn't knew about "-tr-function-alias", indeed this seem like
>>> the right thing to do. Will try this out. About speed, for the number of
>>> time you use the change language during runtime, it doesn't really matter,
>>> if it take a few ms more.
>>>
>>> Thanks for the tips!
>>>
>>> On Thu, Mar 3, 2016 at 2:37 PM, Julien Cugnière <
>>> julien.cugni...@gmail.com> wrote:

 2016-03-03 18:50 GMT+01:00 Jérôme Godbout :
 > We did the same thing into Qml, we have a C++ singleton equivalent to
 your
 > backend, that select the current language files and emit the QString
 > property changed.
 > qsTr("String to convert") + I18n.revaluate
 >
 > I wish they made underlying hook to revaluate the qsTr() with a signal
 > connected like if the qsTr() have changed. This pollute the code all
 over,
 > only to be able to swap language on the fly.

 Just an idea : you might be able to hide that I18n.revaluate with
 something along the lines of :

 function myTr(s) {
 return qsTr(s) + I18n.revaluate;
 }

 Text {
 text: myTr("String to convert")
 }

 Then you need to get lupdate to understand "myTr", which can be done
 with the command line option "-tr-function-alias qsTr=myTr".

 Although this incurs the overhead of a function call, which might
 prevent QML from using its fast path for bindings evaluation. Not sure
 if it matters.

 Julien Cugnière
>>>
>>> ___ Interest mailing list
>> Interest@qt-project.org
>> http://lists.qt-project.org/mailman/listinfo/interest
>>
>
>
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Dynamic translations for mobile apps at runtime?

2016-03-04 Thread Jérôme Godbout
>  "-tr-function-alias qsTr=MySingleton.myqsTr"
That's what I tried but it didn't work sadly. That would have solve it
nicely.

On Thu, Mar 3, 2016 at 5:43 PM, Jason H  wrote:

> What if you did "-tr-function-alias qsTr=MySingleton.myqsTr" ?
>
> *Sent:* Thursday, March 03, 2016 at 5:31 PM
> *From:* "Jérôme Godbout" 
> *To:* "Julien Cugnière" 
> *Cc:* "interest@qt-project.org" 
> *Subject:* Re: [Interest] Dynamic translations for mobile apps at runtime?
> I test it out, it work as long as the function is a direct function
> access, you can't use module call like
>
> MySingleton.myqsTr("My String") // don't work, lupdate does get this one
> myqsTr("My String") // work
>
> Could have put the function into it's own javascript .pragma library and
> just import it in needed file. Is their a way to declare a global
> javascript function into the engine with the binding still working? I just
> don't want to add the function on each file if possible:
>
> *function myqsTr(str) { return qsTr(str) + I18n.revaluate; }*
>
> I may try to add the function into the RootItem of the QQuickView and hope
> the context hierarchies will always find it everywhere to see if this work.
>
> That's so close to work well...
>
>
>
> On Thu, Mar 3, 2016 at 3:41 PM, Jérôme Godbout 
> wrote:
>>
>> Nice, I didn't knew about "-tr-function-alias", indeed this seem like
>> the right thing to do. Will try this out. About speed, for the number of
>> time you use the change language during runtime, it doesn't really matter,
>> if it take a few ms more.
>>
>> Thanks for the tips!
>>
>> On Thu, Mar 3, 2016 at 2:37 PM, Julien Cugnière <
>> julien.cugni...@gmail.com> wrote:
>>>
>>> 2016-03-03 18:50 GMT+01:00 Jérôme Godbout :
>>> > We did the same thing into Qml, we have a C++ singleton equivalent to
>>> your
>>> > backend, that select the current language files and emit the QString
>>> > property changed.
>>> > qsTr("String to convert") + I18n.revaluate
>>> >
>>> > I wish they made underlying hook to revaluate the qsTr() with a signal
>>> > connected like if the qsTr() have changed. This pollute the code all
>>> over,
>>> > only to be able to swap language on the fly.
>>>
>>> Just an idea : you might be able to hide that I18n.revaluate with
>>> something along the lines of :
>>>
>>> function myTr(s) {
>>> return qsTr(s) + I18n.revaluate;
>>> }
>>>
>>> Text {
>>> text: myTr("String to convert")
>>> }
>>>
>>> Then you need to get lupdate to understand "myTr", which can be done
>>> with the command line option "-tr-function-alias qsTr=myTr".
>>>
>>> Although this incurs the overhead of a function call, which might
>>> prevent QML from using its fast path for bindings evaluation. Not sure
>>> if it matters.
>>>
>>> Julien Cugnière
>>
>> ___ Interest mailing list
> Interest@qt-project.org
> http://lists.qt-project.org/mailman/listinfo/interest
>
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] scaling QRect inside a QWidget

2016-03-04 Thread Nicolas Jäger
Le Fri, 4 Mar 2016 10:29:11 +0200,
Nye  a écrit :

> Hello Nicolas,
> > just scaling the widget don't resize the QRect  
> I don't see a reason this should happen automatically, you're supposed to
> scale your rect yourself.
ok


> > But first, since widths are int, I have to make a conversion to float  
> then to int, who brings some rounding errors.
> This is expected, you can't keep precision when truncating from floating
> point to integers. However, the errors are in the range of +-1, so in most
> cases this shouldn't be a problem.
> 
> > And for some reason when I pass the value my QRect doesn't get the good  
> value (note that, this may comes from our code).
> Possibly an error in your code, try debugging it and tracing the reason for
> that.
that's going to be my task today... I will first use a dummy qrect to see the 
difference with my
actual qrect then bugging the code with a lot of qdebug to see where I do some 
change on that
actual rectangle, etc.

> You could use QRectF, which employs floating point coordinates, if that
> suits you better.
that"s may be a solution

thx,
Regards,
Nicolas
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] famous issue : setMouseTracking

2016-03-04 Thread Nicolas Jäger
hi,

> > if some widget has the setMouseTracking set to true, the event  
> mouseMoveEvent is detected only when a clicked is perfomed.
> 
> This doesn't sound right, enabling the mouse tracking causes mouse move
> events to be dispatched to the widget without the need to have a mouse
> click (provided the mouse is hovering over the widget, if not, mouse
> tracking doesn't do you any good).
yes it's doesn't sound right,that's why I try to figure what's going on. You 
can easily find some
topics about that problem on internet.

> 
> >  I set the SetMouseTracking to true when the mouse enters the widget, and  
> I set it to false when the mouse leave the widget. The reason I do that, I
> read somewhere on internet (I didn't kept the link sry) that only one
> widget at a time can truly have  settled to true. and I
> want to use it for several widgets.
> 
> No need to do that. Just enable the mouse tracking for whichever widget you
> want to receive the mouse move events. I believe you're confusing the mouse
> tracking with grabbing the mouse, which is exclusive.

Initially I just set several widget with setMouseTracking but it didn't worked. 
No, I'm not
confusing between tracking and grabbing. I have no use of grabing.

Regards,
Nicolas
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Regarding QtreeWidget

2016-03-04 Thread william.croc...@analog.com

On 03/04/2016 03:06 AM, Roshni Lalwani wrote:

I have application in which I am planning to use a QtreeWidget . The maxinum
number of elements in the treeWidget can go uptp 500 . COuld you let me how will
be performance of using QtreeWidget for 500 elements . Will it lead to some
performance degradation



Use a QTreeView with an underlying model and performance of the tree widget
will no longer be a concern.


Regards
Roshni


___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest

___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


[Interest] Fwd: Minimum required OS X SDK for Qt 5.6?

2016-03-04 Thread NoRulez



Anfang der weitergeleiteten E‑Mail:

> Von: NoRulez 
> Datum: 4. März 2016 um 10:46:15 MEZ
> An: Tim Blechmann 
> Betreff: Re: [Interest] Minimum required OS X SDK for Qt 5.6?
> 
> My current problem is that if I use a newer SDK than 10.8 and/or if I add 
> libc++ than my external library doesn't link anymore.
> 
> Am 04.03.2016 um 09:00 schrieb Tim Blechmann :
> 
 what is the minimum required Mac OS X SDK?
>>> 
>>> Latest. There's no point in using any SDK but the latest.
>>> 
>>> You can compile applications (and Qt itself) to target older OSes, even 
>>> with 
>>> the latest SDK.
>> 
>> in theory yes, in practice YMMV. especially there was an ABI breakage
>> between 10.8 to 10.9 SDKs wrt exception handling
>> 
>> ___
>> Interest mailing list
>> Interest@qt-project.org
>> http://lists.qt-project.org/mailman/listinfo/interest
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] scaling QRect inside a QWidget

2016-03-04 Thread Nye
Hello Nicolas,
> just scaling the widget don't resize the QRect
I don't see a reason this should happen automatically, you're supposed to
scale your rect yourself.

> But first, since widths are int, I have to make a conversion to float
then to int, who brings some rounding errors.
This is expected, you can't keep precision when truncating from floating
point to integers. However, the errors are in the range of +-1, so in most
cases this shouldn't be a problem.

> And for some reason when I pass the value my QRect doesn't get the good
value (note that, this may comes from our code).
Possibly an error in your code, try debugging it and tracing the reason for
that.

> But I try to figure if there is another way than computing width, height,
new position of the QRect.
You could use QRectF, which employs floating point coordinates, if that
suits you better.

Kind regards,
Konstantin.


On Fri, Mar 4, 2016 at 3:28 AM, Nicolas Jäger 
wrote:

> Hi Nye and others,
>
> I use the resize event, the problem is how can I scale properly the QRect,
> because just scaling the
> widget don't resize the QRect. I try to compute the ratio =
> newWidth/oldWidth of widget then doing
> newWidthOfQRect * ratio. But first, since widths are int, I have to make a
> conversion to float then
> to int, who brings some rounding errors.
>
> And for some reason when I pass the value my QRect doesn't get the good
> value (note that, this may
> comes from our code). But I try to figure if there is another way than
> computing width, height, new
> position of the QRect.
>
> Regards,
> Nicolas
>
>
>
> > You could intercept the QWidget's resize event either by providing an
> > override (http://doc.qt.io/qt-5/qwidget.html#resizeEvent) or by
> installing
> > an event filter (
> http://doc.qt.io/qt-5/eventsandfilters.html#event-filters).
> > Note, however, you'll receive a resize event on initialization of the
> > widget as well.
> >
> > Kind regards.
> >
> > On Fri, Mar 4, 2016 at 2:11 AM, Nicolas Jäger 
> > wrote:
> >
> > > Hi,
> > >
> > > I have a QRect inside a QWidget and I would like to scale it when the
> > > widget is scaled by the user.
> > > There is a QtThing to do that ?
> > >
> > > regards,
> > > Nicolas
> > > ___
> > > Interest mailing list
> > > Interest@qt-project.org
> > > http://lists.qt-project.org/mailman/listinfo/interest
> > >
>
> ___
> Interest mailing list
> Interest@qt-project.org
> http://lists.qt-project.org/mailman/listinfo/interest
>
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] famous issue : setMouseTracking

2016-03-04 Thread Nye
Hello Nicolas,

> if some widget has the setMouseTracking set to true, the event
mouseMoveEvent is detected only when a clicked is perfomed.

This doesn't sound right, enabling the mouse tracking causes mouse move
events to be dispatched to the widget without the need to have a mouse
click (provided the mouse is hovering over the widget, if not, mouse
tracking doesn't do you any good).

>  I set the SetMouseTracking to true when the mouse enters the widget, and
I set it to false when the mouse leave the widget. The reason I do that, I
read somewhere on internet (I didn't kept the link sry) that only one
widget at a time can truly have setMouseTracking settled to true. and I
want to use it for several widgets.

No need to do that. Just enable the mouse tracking for whichever widget you
want to receive the mouse move events. I believe you're confusing the mouse
tracking with grabbing the mouse, which is exclusive.

Kind regards,
Konstantin.

On Fri, Mar 4, 2016 at 3:45 AM, Nicolas Jäger 
wrote:

> Hi,
>   I have a question many time asked on internet, why even if some widget
> has the setMouseTracking
>   set to true, the event mouseMoveEvent is detected only when a clicked is
> perfomed.
>
>   I don't just setMouseTracking, I did a grep over the whole project to be
> sure that there is no
>   other SetMouseTracking.
>
>   Also, I set the SetMouseTracking to true when the mouse enters the
> widget, and I set it to false
>   when the mouse leave the widget. The reason I do that, I read somewhere
> on internet (I didn't
>   kept the link sry) that only one widget at a time can truly have
> setMouseTracking settled to
>   true. and I want to use it for several widgets.
>
>   in my mouse move event function,I added some qDebug() <<
> hasMouseTracking() who always returns
>   true when the event is performed (by clicking).I also added som
> qDebug()s in enter/leave events
>   functions. everybody looks fine but I don't have my mouseMoveEvent
> performed.
>
>   I really would like to solve this issue wich is really annoying in my
> case. I don't know if I
>   misunderstood something or what-what...
>
>   or is it a bug ?
>
> Regards,
> Nicolas
> ___
> Interest mailing list
> Interest@qt-project.org
> http://lists.qt-project.org/mailman/listinfo/interest
>
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


[Interest] Regarding QtreeWidget

2016-03-04 Thread Roshni Lalwani
I have application in which I am planning to use a QtreeWidget . The
maxinum number of elements in the treeWidget can go uptp 500 . COuld you
let me how will be performance of using QtreeWidget for 500 elements . Will
it lead to some performance degradation

Regards
Roshni
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Minimum required OS X SDK for Qt 5.6?

2016-03-04 Thread Tim Blechmann
>> what is the minimum required Mac OS X SDK?
> 
> Latest. There's no point in using any SDK but the latest.
> 
> You can compile applications (and Qt itself) to target older OSes, even with 
> the latest SDK.

in theory yes, in practice YMMV. especially there was an ABI breakage
between 10.8 to 10.9 SDKs wrt exception handling

___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest