Re: [Interest] Are there fixes for QWebEngine?

2016-01-18 Thread Joerg Bornemann

On 17-Jan-16 19:12, NoRulez wrote:


I used the official Beta installer.


I've just checked the beta installer. Building the demobrowser example 
works fine here. If you still feel that you've found a bug, please 
create a bug report.



BR,

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


Re: [Interest] invalidated copies of QString in QCommonStyle::cachedOption

2016-01-18 Thread Igor Mironchik



On 18.01.2016 13:46, Mojmír Svoboda wrote:

On 18.1.2016 10:21, Igor Mironchik wrote:


Can you reset model on closing of your table view, drop any data, etc...
And then close view.


Yes i am doing that. I am trying to close everything i know
i created (models, proxy models, context menus, delegates).
But the problem persists.


What if to change QStringLiteral with QLatin1String usage?



While inpecting the code i came to think that this class 
(QWindowsVistaStyle in current case) is not deleted when i close my 
table, but rather shared between multiple widgets. If i take

QStyle * s0 =  m_main_window->dockManager().style(); for example
where dockManager() is an unrelated QTreeView, the .text field in this
s0 contains .text from completely different QTableView (the one that
i am closing).


If I understood your correctly you are loading model again on new show?


i have one widget right from start, this is the dockManager with the 
style s0. This widget is the first to create and therefore
i think it's the first to create the style via QStyleFactory. Some 
(all?) subsequent views seems to re-use this s0.


And then there is this QTableView that opens when tcp connection with 
data comes and closed on new connection with new data or user request.


Mojmir
___
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] invalidated copies of QString in QCommonStyle::cachedOption

2016-01-18 Thread Mojmír Svoboda

Hello,

i have a crash in QCommonStyle::subElementRect

case SE_ItemViewItemDecoration:
case SE_ItemViewItemText:
case SE_ItemViewItemFocusRect:
if (const QStyleOptionViewItem *vopt = ...) {
if (!d->isViewItemCached(*vopt)) {
d->viewItemLayout(...);
if (d->cachedOption) {
delete d->cachedOption;
d->cachedOption = 0;
}
d->cachedOption = new QStyleOptionViewItem(*vopt);
}

with callstack:
  QArrayData::deallocate
  QTypedArrayData::deallocate(QArrayData * data)
  QString::~QString() Line 1070
  QStyleOptionViewItem::~QStyleOptionViewItem()
  QStyleOptionViewItem::`scalar deleting destructor'(unsigned int)
> QCommonStyle::subElementRect(QStyle::SubElement sr, const 
QStyleOption * opt, const QWidget * widget) Line 2993

  QWindowsStyle::subElementRect
  QWindowsVistaStyle::subElementRect
  QCommonStyle::drawControl
  QWindowsStyle::drawControl
  QWindowsVistaStyle::drawControl
  QStyledItemDelegate::paint
  QTableViewPrivate::drawCell
  QTableView::paintEvent
  ...


How this occurs:
i have QTableView with custom model that uses memmapped file filled with 
lots of QStringData. These QStringData are set using the technique 
presented in http://woboq.com/blog/qstringliteral.html for example.


The problem is when the storage goes away (widget is closed), because 
there may be copies of those strings, and indeed they are.


One of the copies is in QCommonStylePrivate::cachedOption::text field. I
suspect these style classes use some form of sharing, so when i close 
the widget, the copy of qstring will survive the storage, and then when 
new qtableview opens, it tries to reuse the style and on the first use 
it destroys the old content of .text field and crash follows.


Now what do i do? Try to force somehow the style class to drop the 
d->cachedOption?

Any ideas, please?

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


Re: [Interest] invalidated copies of QString in QCommonStyle::cachedOption

2016-01-18 Thread Mojmír Svoboda

On 18.1.2016 10:21, Igor Mironchik wrote:


Can you reset model on closing of your table view, drop any data, etc...
And then close view.


Yes i am doing that. I am trying to close everything i know
i created (models, proxy models, context menus, delegates).
But the problem persists.

While inpecting the code i came to think that this class 
(QWindowsVistaStyle in current case) is not deleted when i close my 
table, but rather shared between multiple widgets. If i take

QStyle * s0 =  m_main_window->dockManager().style(); for example
where dockManager() is an unrelated QTreeView, the .text field in this
s0 contains .text from completely different QTableView (the one that
i am closing).


If I understood your correctly you are loading model again on new show?


i have one widget right from start, this is the dockManager with the 
style s0. This widget is the first to create and therefore
i think it's the first to create the style via QStyleFactory. Some 
(all?) subsequent views seems to re-use this s0.


And then there is this QTableView that opens when tcp connection with 
data comes and closed on new connection with new data or user request.


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


[Interest] Standardized StackView navigation

2016-01-18 Thread Jason H
What are your thoughts with extending StackView (maybe a derived class called 
'ScreenStack' or 'ActivityStack')

I've done a number of mobile-paradigm based apps, and seem to be convergently 
evolving the same pattern.

main.qml {
ScreenStack {}
Screen1 {}
Screen2 {}
Screen3 {}
Screen4 {}
}

Screen.qml {
visible: false
// lifecycle
signal created();
signal entered();
signal exited();
signal destroyed();
// navigation
signal next();
signal back();
}

ScreenX.qml {
 Screen {
 }
}

Which is similar to android, minus the pause/resume. ( 
http://developer.android.com/reference/android/app/Activity.html#ActivityLifecycle
 )

I figure it would be cool to have a 'ScreenView' that would properly instrument 
the lifecycle, and potentially the navigation.
Currently, I implement entered/exited with onVisibleChanged, destroyed is not 
implemented, and created is Component.onCompleted.

I also have used this to implement dynamic workflows. To avoid Apple app store 
restrictions, a JSON object was retrieved from the server which contained the 
names of QML files, which existed locally in the application, with a trivial 
decision tree to decide the next screen. In this case, each screen was 
dynamically created.

Thoughts?





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


[Interest] Add margin spacing between QComboBox item icon and text ?

2016-01-18 Thread Edward Sutton
When the QComboBox drop-down is activated, the icons overlay the text making it 
hard to read.

Is there a property or style sheet to adjust this?

For the currently selected its, the icon and text have good spacing QComboBox.

[cid:329FA5E8-77C2-4F8C-8849-96D4DEB58A7A@ditchwitch.cmw.internal]


Item icon overlays text.

[cid:25C66223-AD31-4A3E-9CE5-00FAA45ACD50@ditchwitch.cmw.internal]


Thanks,

-Ed



This email and any files transmitted with it from The Charles Machine Works, 
Inc. are confidential and intended solely for the use of the individual or 
entity to which they are addressed. If you have received this email in error 
please notify the sender. Our company accepts no liability for the contents of 
this email, or for the consequences of any actions taken on the basis of the 
information provided, unless that information is subsequently confirmed in 
writing. Please note that any views or opinions presented in this email are 
solely those of the author and do not necessarily represent those of the 
company. Finally, the recipient should check this email and any attachments for 
the presence of viruses. The company accepts no liability for any damage caused 
by any virus transmitted by this email.
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Add margin spacing between QComboBox item icon and text ?

2016-01-18 Thread Bo Thorsen

Den 18-01-2016 kl. 19:36 skrev Edward Sutton:

When the QComboBox drop-down is activated, the icons overlay the text
making it hard to read.

Is there a property or style sheet to adjust this?

For the currently selected its, the icon and text have good spacing
QComboBox.

Item icon overlays text.


I don't know what you did, but that's not how it normally looks. 
Obviously not.


Bo Thorsen,
Director, Viking Software.

--
Viking Software
Qt and C++ developers for hire
http://www.vikingsoft.eu
___
Interest mailing list
Interest@qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest


Re: [Interest] Standardized StackView navigation

2016-01-18 Thread Ben Lau
Beside those signals, transition effect should be able to set per view.

In fact, I have already did similar thing in QuickAndroid project. I call
it PageStack.

https://github.com/benlau/quickandroid/blob/master/QuickAndroid/Page.qml
https://github.com/benlau/quickandroid/blob/master/QuickAndroid/PageStack.qml

However, entered/exited signals are not enough. I further break down into
appear / disappear / present / dismiss signals. And it is emitted by Page
component instead of PageStack. Becoz Page component usually need this
those signals to refresh / save content.





On 19 January 2016 at 01:23, Jason H  wrote:

> What are your thoughts with extending StackView (maybe a derived class
> called 'ScreenStack' or 'ActivityStack')
>
> I've done a number of mobile-paradigm based apps, and seem to be
> convergently evolving the same pattern.
>
> main.qml {
> ScreenStack {}
> Screen1 {}
> Screen2 {}
> Screen3 {}
> Screen4 {}
> }
>
> Screen.qml {
> visible: false
> // lifecycle
> signal created();
> signal entered();
> signal exited();
> signal destroyed();
> // navigation
> signal next();
> signal back();
> }
>
> ScreenX.qml {
>  Screen {
>  }
> }
>
> Which is similar to android, minus the pause/resume. (
> http://developer.android.com/reference/android/app/Activity.html#ActivityLifecycle
> )
>
> I figure it would be cool to have a 'ScreenView' that would properly
> instrument the lifecycle, and potentially the navigation.
> Currently, I implement entered/exited with onVisibleChanged, destroyed is
> not implemented, and created is Component.onCompleted.
>
> I also have used this to implement dynamic workflows. To avoid Apple app
> store restrictions, a JSON object was retrieved from the server which
> contained the names of QML files, which existed locally in the application,
> with a trivial decision tree to decide the next screen. In this case, each
> screen was dynamically created.
>
> Thoughts?
>
>
>
>
>
> ___
> 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