Re: [SailfishDevel] Delegate creation on demand

2013-12-15 Thread christopher . lamb

Hi Hendrik

Have you seen this? http://qt-project.org/wiki/Performance_tip_Lists

The general advice is to keep the delegates is lightweight as  
possible, and to use Loaders for anything needed later (e.g. onClick)


Chris

Zitat von "Hendrik Borghorst" :


Hello folks,

I've got a problem with long lists (~25000 elements). All delegates are
created at once which causes the memory usage to explode beyond the
devices capability.

I already tried setting "cacheBuffer: 0" in SiliciaListView but  it
doesn't change it.

Is the something I'm doing wrong.

You can see the actual page code here:

https://github.com/djselbeck/smpc/blob/master/pages/CurrentPlaylistPage.qml

Shouldn't the delegates be constructed on demand? It is weird because my
old n8 wasn't struggling with qml lists with this size.

greetings and congrats on getting the devices to your customers (I'm
very pleased)






___
SailfishOS.org Devel mailing list


Re: [SailfishDevel] Sailfish app to monitor network traffic ?

2013-12-15 Thread acce

Hi,

If you mean the total data transferred, it can be seen in the settings of the 
phone.
AFAIK there is no application for real-time monitoring though.

-Asser

On Sat, 14 Dec 2013 00:58:31 +0100
"W. Dobbe"  wrote:

> Hi all,
> 
> A question to those who already received their Jolla phone: is there an 
> application to monitor the amount of data going over the network, especially 
> over the 3G/4G connection ?
> 
> If not, is there already someone developing one?
> 
> Otherwise I might have a go at it.
> 
> regards,
> 
> Winfried
> ___
> SailfishOS.org Devel mailing list
> 


-- 
Asser 
___
SailfishOS.org Devel mailing list


[SailfishDevel] SailfishOS translations

2013-12-15 Thread Jarno

Hi,

I was wondering if the current SailfishOS UI is ready to be translated 
to more languages. As of yesterday the Dutch Sailors are receiving their 
phones and most of them would love to see a Dutch UI. And even better, 
some of them already said they are willing to help translate. Some of 
them have experience with translating Meego apps and at least two have 
worked on translating Plone CMS (including me). So, plenty of people 
eager to make this happen.



Sincerely,

Jarno de Wit (@jarno, jollanl.org, @jollanl)
___
SailfishOS.org Devel mailing list


[SailfishDevel] SailfishOS (Dutch) translations

2013-12-15 Thread Jarno

Hi,

I was wondering if the current SailfishOS UI is ready to be translated 
to more languages. As of yesterday the Dutch Sailors are receiving their 
phones and most of them would love to see a Dutch UI. And even better, 
some of them already said they are willing to help translate. Some of 
them have experience with translating Meego apps and at least two have 
worked on translating Plone CMS (including me). So, plenty of people 
eager to make this happen.



Sincerely,

Jarno de Wit (@jarno, jollanl.org, @jollanl)
___
SailfishOS.org Devel mailing list


Re: [SailfishDevel] SailfishOS (Dutch) translations

2013-12-15 Thread Javier Ferreira
Waiting for the portuguese
Em 15/12/2013 07:41, "Jarno"  escreveu:

> Hi,
>
> I was wondering if the current SailfishOS UI is ready to be translated to
> more languages. As of yesterday the Dutch Sailors are receiving their
> phones and most of them would love to see a Dutch UI. And even better, some
> of them already said they are willing to help translate. Some of them have
> experience with translating Meego apps and at least two have worked on
> translating Plone CMS (including me). So, plenty of people eager to make
> this happen.
>
>
> Sincerely,
>
> Jarno de Wit (@jarno, jollanl.org, @jollanl)
> ___
> SailfishOS.org Devel mailing list
>
___
SailfishOS.org Devel mailing list

Re: [SailfishDevel] SailfishOS (Dutch) translations

2013-12-15 Thread Superpelican
I wouldn't mind contributing to a Dutch translation either (although I always 
have my SW language set to English myself)

On Sat Dec 14 19:35:21 2013 Jarno  wrote:
> Hi,
> 
> I was wondering if the current SailfishOS UI is ready to be translated 
> to more languages. As of yesterday the Dutch Sailors are receiving their 
> phones and most of them would love to see a Dutch UI. And even better, 
> some of them already said they are willing to help translate. Some of 
> them have experience with translating Meego apps and at least two have 
> worked on translating Plone CMS (including me). So, plenty of people 
> eager to make this happen.
> 
> 
> Sincerely,
> 
> Jarno de Wit (@jarno, jollanl.org, @jollanl)
> ___
> SailfishOS.org Devel mailing list

___
SailfishOS.org Devel mailing list

Re: [SailfishDevel] SailfishOS (Dutch) translations

2013-12-15 Thread Wim de Vries

On 12/15/2013 11:45 AM, Javier Ferreira wrote:


Waiting for the portuguese

Em 15/12/2013 07:41, "Jarno" > escreveu:


Hi,

I was wondering if the current SailfishOS UI is ready to be
translated to more languages. As of yesterday the Dutch Sailors
are receiving their phones and most of them would love to see a
Dutch UI. And even better, some of them already said they are
willing to help translate. Some of them have experience with
translating Meego apps and at least two have worked on translating
Plone CMS (including me). 




So, plenty of people eager to make this happen.


meeto




Sincerely,

Jarno de Wit (@jarno, jollanl.org , @jollanl)
___
SailfishOS.org Devel mailing list



___
SailfishOS.org Devel mailing list


___
SailfishOS.org Devel mailing list

Re: [SailfishDevel] no output from console.log

2013-12-15 Thread Wim de Vries

Thx
On 12/14/2013 11:25 PM, Artem Marchenko wrote:

That is a known issue with this SDK release, unfortunately.

There are two workarounds possible:
1. ssh to emulator console and run "sudo journalctl -fa" there

I am getting a lot of (and no console.log output):


 Logs begin at Sun, 15 Dec 2013 13:08:57 +0200.


 Dec 15 13:22:07 SailfishEmul sshd[912]:
 dispatch_protocol_error: type 128 seq 86


 Dec 15 13:22:14 SailfishEmul sshd[1010]:
 dispatch_protocol_error: type 128 seq 103



2. Switch to test-driven development as qttest console output goes to 
QtCreator just fine :)
See sample tests subprojects at 
https://github.com/amarchen/helloworld-pro-sailfish and 
https://github.com/amarchen/Wikipedia

Scanned through this code, but can find out what to do for this option.


Best regards,
Artem.



On Sat, Dec 14, 2013 at 9:40 PM, Wim de Vries > wrote:


Hi,
Since 1312 I do not get any of the console.log output in the
"application output" window.
Am I overseeing sth.
thanks.
r
wim
___
SailfishOS.org Devel mailing list




--
Artem Marchenko
http://agilesoftwaredevelopment.com
http://twitter.com/AgileArtem


___
SailfishOS.org Devel mailing list


___
SailfishOS.org Devel mailing list

[SailfishDevel] (silica)listview without model?

2013-12-15 Thread Wim de Vries

Hi,
Working on the GUI port from QWidgets to QML.
I am trying the ContextMenu example in the documentation.
It does not work: I did see that the SilicaListView has no model (in the 
QML documentation there is always a model).

Same goes for the ListItem example.
Is Sailfish different from QML here?
Thanks.
r
wim
___
SailfishOS.org Devel mailing list


Re: [SailfishDevel] (silica)listview without model?

2013-12-15 Thread christopher . lamb

Hi Wim

Of course a ListView (Silica or otherwise) requires a model. Without a  
model the View would not make much sense 8-)


The Listview documentation shows this.

https://sailfishos.org/sailfish-silica/qml-sailfishsilica-silicalistview.html

I suspect the ContextModel documentation is over-simplified.

Chris

Zitat von "Wim de Vries" :


Hi,
Working on the GUI port from QWidgets to QML.
I am trying the ContextMenu example in the documentation.
It does not work: I did see that the SilicaListView has no model (in  
the QML documentation there is always a model).

Same goes for the ListItem example.
Is Sailfish different from QML here?
Thanks.
r
wim
___
SailfishOS.org Devel mailing list






___
SailfishOS.org Devel mailing list


[SailfishDevel] qmlscene & error handling

2013-12-15 Thread Osmo Salomaa

Hello,

I'm writing an application using QML and PyOtherSide. I'm new to Qt, 
QML, PyOtherSide and all the rest apart from Python.


I ssh into the emulator and use 'qmlscene main.qml' to run my 
application. I'm wondering about qmlscene's error handling. I create QML 
objects dynamically based on data sent from the Python side. If I have 
an error in my QML code, qmlscene seems to just silently stop executing 
code at the offending point. I'd expect an error message, maybe even a 
crash. Why don't I get that?


Two examples of these ignored errors: (1) I was referring to an object 
by its id apparently out of scope, solved by moving the Python block 
from under ApplicationWindow to under Page and (2) I mistyped a method 
call, 'addItem' instead of 'addMapItem'.


--
Osmo Salomaa 
___
SailfishOS.org Devel mailing list


Re: [SailfishDevel] qmlscene & error handling

2013-12-15 Thread Wim de Vries
I don't  know about Python, but QML is giving no feedback at all (even 
console.log does not work) since the SDK update.

See " no output from console.log" topic above. Possibly related.
r
wim

On 12/15/2013 05:19 PM, Osmo Salomaa wrote:

Hello,

I'm writing an application using QML and PyOtherSide. I'm new to Qt, 
QML, PyOtherSide and all the rest apart from Python.


I ssh into the emulator and use 'qmlscene main.qml' to run my 
application. I'm wondering about qmlscene's error handling. I create 
QML objects dynamically based on data sent from the Python side. If I 
have an error in my QML code, qmlscene seems to just silently stop 
executing code at the offending point. I'd expect an error message, 
maybe even a crash. Why don't I get that?


Two examples of these ignored errors: (1) I was referring to an object 
by its id apparently out of scope, solved by moving the Python block 
from under ApplicationWindow to under Page and (2) I mistyped a method 
call, 'addItem' instead of 'addMapItem'.




___
SailfishOS.org Devel mailing list


Re: [SailfishDevel] A new Jolla phone user - after 2 days of use

2013-12-15 Thread Kari Pihkala
> > 2. There should be a way to go straight from Lock Screen to Launcher
> > (instead of needing to go through Home)
>
> i don't agree, for multi-processing this is better, plus there's a pulley
> menu on lock for the relevant apps... i suppose this is configurable

I also have difficulties with the Home screen and I would rather use the
Launcher screen to switch between apps. I think the reason is that

in Home screen:

 * Covers move around so I have to go through them one by one to find the
app I need. Only if I continuously swap between two apps, I might trust
that the app is the first or second one in the grid.
 * Cover texts/images change, so I have to read/decypher images to
understand which app they relate to. This is slow.

in Launcher screen:

 * App icons don't move around. I can rely on my spatial memory and find
the app always at the same spot. Often, I have already moved my finger over
the app before the screen has stopped scrolling.
 * App icons don't change. Recognizing a familiar icon is faster than
reading/decyphering images.

Perhaps the number of covers displayed on Home could be customizable? I
would limit it to three small ones (or remove all). The app icons could
move up to occupy the free space.

Also pinning the covers would help (I would pin most of them).

I never close apps, so I have all the time nine small covers on the Home
screen. Am I doing it wrong?

Cheers,
Kari



2013/12/14 AL13N 

> > Hi,
> >
> > Moving from N9/Meego two days ago, I find Jolla/Sailfish very easy to
> use,
> > and have some feedback (wishlist?). I hope this is the right place for
> > this feedback, otherwise please point me to the correct place.
>
> i'm not a jolla dev, nor do i have a jolla, but i'll reply and give my
> thoughts...
>
> > Current version: 1.0.1.10 (notification for version upgrade came almost
> > immediate I got online)
> >
> > Sailfish/Platform specific:
> > 1. From Lock Screen, swiping-up should bring me to Home screen, but it
> > often brings up the Events screen even if there is no
> > notifications/events. A friend's N9 community edition Sailfish allows
> > swiping from the left/right side on Lock screen - the same doesn’t work
> on
> > my Jolla.
>
> if you swipe up from the bottom, it brings event screen, if you swipe up
> from the middle, it brings home screen. takes some getting used to...
>
> maybe swiping left/right doens't work if you don't have a TOH?
>
> > 2. There should be a way to go straight from Lock Screen to Launcher
> > (instead of needing to go through Home)
>
> i don't agree, for multi-processing this is better, plus there's a pulley
> menu on lock for the relevant apps... i suppose this is configurable
>
> > 3. Easier (less taps) accessible configuration (eg WLAN, Bluetooth) from
> > any screen (not just "Settings")
>
> wasn't there some kind of cover where you could do this? there's been a
> request for pinning covers, i would like this in combination...
>
> > 4. Need easier way view the current connection (All the connection
> related
> > icons on Lock Screen are hard to decode at least initially - in
> particular
> > for the Mobile Network Data icon, but WLAN icon also hard to decode)
> > 5. More configurable settings (colour selection for text/notification
> > icons/etc, background picture, additional items to be displayed on Lock
> > screen)
>
> this is done via ambience iinm, but i agree that this Abience should
> really be allowed to be tuned/configured a bit...
>
> > 6. Icon's Text on Launcher screen feels a bit hard to read (doesn’t look
> > very solid)
>
> Ambience?
>
> > 7. Add ability to have different colours to different inbuilt apps (eg.
> > Phone, messaging/SMS, etc) - they currently all look very similar on the
> > Home screen and colour differentiation would help usability greatly.
>
> i think this would have issues with different Ambiences
>
> > 8. Auto-correct while typing (maybe as a configurable option)
> > 9. Please bring Swype to Sailfish!
> > 10. Chinese writing input (find the button = with extra -, that should
> allow configuration) i heard this on #jollamobile at freenode IRC
>
>
>
> >
> > Jolla Applications:
> > 1. Sometimes Email's connection frequency setting does not appear to be
> > observed - email isnt checked every 30 minutes as I had configured, and
> > Exchange email isnt "pushed" to me
> > 2. Clock: configurable snooze time? ;-)
> >
> > Android Support:
> > 1. Whatsapp address book does not work - currently all my Whatsapp
> > Contacts are empty. Understand this is due to Whatsapp on Android cannot
> > reach Jolla's phone book - can this be fixed?
> > 2. Would be great if Android apps can appear as individual/independent
> > apps instead of a single "Virtual Machine" which all Android apps live
> > inside.
> >
> > Jolla Store:
> > 1. Jolla App store feels a bit confusing - dont really know what apps are
> > there as the only clear "catalog" available is the list of apps built by
> > Jolla - all other Apps are scattered
> >
>

Re: [SailfishDevel] qmlscene & error handling

2013-12-15 Thread Osmo Salomaa

15.12.2013 18:30, Wim de Vries wrote:

I don't  know about Python, but QML is giving no feedback at all (even
console.log does not work) since the SDK update.
See " no output from console.log" topic above. Possibly related.


I'm still on the previous version. console.log works.

--
Osmo Salomaa 
___
SailfishOS.org Devel mailing list


Re: [SailfishDevel] working on apps?

2013-12-15 Thread AL13N
> I'm porting the modRana flexible navigation system[1][2] to Sailfish
> and I plan to also port the Mieru offline manga and comic book
> reader[3][4]. :)

what about MangaWhat ? i use that one :-)

___
SailfishOS.org Devel mailing list


Re: [SailfishDevel] working on apps?

2013-12-15 Thread AL13N
> Currency Converter: https://github.com/tanghus/currency-converter-qml
> Kitchen Timer: https://github.com/tanghus/kitchen-timer-qml
>
> The capcha for your site is ridiculous, so posting it here instead :)

It's not my site (it's for embedded linux), but that captcha _is_
ridiculous... i couldn't answer one question, after dozens of reloads, i
ended up researching the Linus Torvalds question and cycle the captcha
until i got that one... :-(

Since we don't have anything yet, this is a place where we can put some
documentation until there might be a better place... though, otoh, since
this is about embedded Linux, it's not exactly a wrong place either...

___
SailfishOS.org Devel mailing list


Re: [SailfishDevel] working on apps?

2013-12-15 Thread David Greaves
On 15/12/13 17:41, AL13N wrote:
>> Currency Converter: https://github.com/tanghus/currency-converter-qml
>> Kitchen Timer: https://github.com/tanghus/kitchen-timer-qml
>>
>> The capcha for your site is ridiculous, so posting it here instead :)
> 
> It's not my site (it's for embedded linux), but that captcha _is_
> ridiculous... i couldn't answer one question, after dozens of reloads, i
> ended up researching the Linus Torvalds question and cycle the captcha
> until i got that one... :-(
> 
> Since we don't have anything yet, this is a place where we can put some
> documentation until there might be a better place... though, otoh, since
> this is about embedded Linux, it's not exactly a wrong place either...

There's always:

  https://wiki.merproject.org/wiki/Sailfish

Which has been around since Mar 2013 :)

David
___
SailfishOS.org Devel mailing list


Re: [SailfishDevel] working on apps?

2013-12-15 Thread Marko Koschak

Hi

I am porting KeepassX (v0.4.3) to Sailfish -> 
https://github.com/jobe-m/ownkeepass

It's quite usable. Needs some polishing until it goes to harbour ;)

Cheers,
Marko

Am Samstag, den 14.12.2013, 11:41 +0100 schrieb "AL13N" 
:
if there are people who are working on apps, and want to let it know, 
so
that no other devs will waste time making the same apps, you can add 
these

here:

http://elinux.org/Jolla

in the appriopriate section.

Thanks!

___
SailfishOS.org Devel mailing list


___
SailfishOS.org Devel mailing list


Re: [SailfishDevel] Delegate creation on demand

2013-12-15 Thread Hendrik Borghorst
Hello,

the problem isn't my delegate. It is quite minimal. 

The problem is I think a bug in QML Listview. It goes absolutly crazy if
it is invisible and starts making delegate for around 50% of all items.
This causes the memory to run full.

A workaround I added is

model: visible ? modelVar : null

which works quite nicely. I think this bug could be an upstream qt bug?

greetings

Am Sonntag, den 15.12.2013, 10:01 +0100 schrieb
christopher.l...@thurweb.ch:
> Hi Hendrik
> 
> Have you seen this? http://qt-project.org/wiki/Performance_tip_Lists
> 
> The general advice is to keep the delegates is lightweight as  
> possible, and to use Loaders for anything needed later (e.g. onClick)
> 
> Chris
> 
> Zitat von "Hendrik Borghorst" :
> 
> > Hello folks,
> >
> > I've got a problem with long lists (~25000 elements). All delegates are
> > created at once which causes the memory usage to explode beyond the
> > devices capability.
> >
> > I already tried setting "cacheBuffer: 0" in SiliciaListView but  it
> > doesn't change it.
> >
> > Is the something I'm doing wrong.
> >
> > You can see the actual page code here:
> >
> > https://github.com/djselbeck/smpc/blob/master/pages/CurrentPlaylistPage.qml
> >
> > Shouldn't the delegates be constructed on demand? It is weird because my
> > old n8 wasn't struggling with qml lists with this size.
> >
> > greetings and congrats on getting the devices to your customers (I'm
> > very pleased)
> >
> 
> 
> 
> 



signature.asc
Description: This is a digitally signed message part
___
SailfishOS.org Devel mailing list

Re: [SailfishDevel] Delegate creation on demand

2013-12-15 Thread Andrey Kozhevnikov

load model dynamically?

if you wont preload model before using it can solve many problems.
:)

On 16.12.2013 02:03, Hendrik Borghorst wrote:

Hello,

the problem isn't my delegate. It is quite minimal.

The problem is I think a bug in QML Listview. It goes absolutly crazy if
it is invisible and starts making delegate for around 50% of all items.
This causes the memory to run full.

A workaround I added is

model: visible ? modelVar : null

which works quite nicely. I think this bug could be an upstream qt bug?

greetings

Am Sonntag, den 15.12.2013, 10:01 +0100 schrieb
christopher.l...@thurweb.ch:

Hi Hendrik

Have you seen this? http://qt-project.org/wiki/Performance_tip_Lists

The general advice is to keep the delegates is lightweight as
possible, and to use Loaders for anything needed later (e.g. onClick)

Chris

Zitat von "Hendrik Borghorst" :


Hello folks,

I've got a problem with long lists (~25000 elements). All delegates are
created at once which causes the memory usage to explode beyond the
devices capability.

I already tried setting "cacheBuffer: 0" in SiliciaListView but  it
doesn't change it.

Is the something I'm doing wrong.

You can see the actual page code here:

https://github.com/djselbeck/smpc/blob/master/pages/CurrentPlaylistPage.qml

Shouldn't the delegates be constructed on demand? It is weird because my
old n8 wasn't struggling with qml lists with this size.

greetings and congrats on getting the devices to your customers (I'm
very pleased)








___
SailfishOS.org Devel mailing list


___
SailfishOS.org Devel mailing list

Re: [SailfishDevel] working on apps?

2013-12-15 Thread Hendrik Borghorst
Hello,

I've ported my MPD (musicpd) Client qmobilempd from symbian. It is
already in harbour but a new version which fixes a lot of crashes is
pending QA.

greetings

Am Samstag, den 14.12.2013, 11:41 +0100 schrieb AL13N:
> if there are people who are working on apps, and want to let it know, so
> that no other devs will waste time making the same apps, you can add these
> here:
> 
> http://elinux.org/Jolla
> 
> in the appriopriate section.
> 
> Thanks!
> 
> ___
> SailfishOS.org Devel mailing list



signature.asc
Description: This is a digitally signed message part
___
SailfishOS.org Devel mailing list

Re: [SailfishDevel] Delegate creation on demand

2013-12-15 Thread Hendrik Borghorst
What do you mean exactly?

Isn't this exactly what ListView should do automatically which can be
influenced with cacheBuffer? Which by the way works correctly as long as
the listview stays visible. 

greetings


Am Montag, den 16.12.2013, 02:05 +0600 schrieb Andrey Kozhevnikov:
> load model dynamically?
> 
> if you wont preload model before using it can solve many problems.
> :)
> 
> On 16.12.2013 02:03, Hendrik Borghorst wrote:
> 
> > Hello,
> > 
> > the problem isn't my delegate. It is quite minimal. 
> > 
> > The problem is I think a bug in QML Listview. It goes absolutly crazy if
> > it is invisible and starts making delegate for around 50% of all items.
> > This causes the memory to run full.
> > 
> > A workaround I added is
> > 
> > model: visible ? modelVar : null
> > 
> > which works quite nicely. I think this bug could be an upstream qt bug?
> > 
> > greetings
> > 
> > Am Sonntag, den 15.12.2013, 10:01 +0100 schrieb
> > christopher.l...@thurweb.ch:
> > > Hi Hendrik
> > > 
> > > Have you seen this? http://qt-project.org/wiki/Performance_tip_Lists
> > > 
> > > The general advice is to keep the delegates is lightweight as  
> > > possible, and to use Loaders for anything needed later (e.g. onClick)
> > > 
> > > Chris
> > > 
> > > Zitat von "Hendrik Borghorst" :
> > > 
> > > > Hello folks,
> > > > 
> > > > I've got a problem with long lists (~25000 elements). All delegates are
> > > > created at once which causes the memory usage to explode beyond the
> > > > devices capability.
> > > > 
> > > > I already tried setting "cacheBuffer: 0" in SiliciaListView but  it
> > > > doesn't change it.
> > > > 
> > > > Is the something I'm doing wrong.
> > > > 
> > > > You can see the actual page code here:
> > > > 
> > > > https://github.com/djselbeck/smpc/blob/master/pages/CurrentPlaylistPage.qml
> > > > 
> > > > Shouldn't the delegates be constructed on demand? It is weird because my
> > > > old n8 wasn't struggling with qml lists with this size.
> > > > 
> > > > greetings and congrats on getting the devices to your customers (I'm
> > > > very pleased)
> > > > 
> > > 
> > > 
> > > 
> > 
> > 
> > ___
> > SailfishOS.org Devel mailing list
> 
> ___
> SailfishOS.org Devel mailing list



signature.asc
Description: This is a digitally signed message part
___
SailfishOS.org Devel mailing list

Re: [SailfishDevel] Delegate creation on demand

2013-12-15 Thread Andrey Kozhevnikov

no, i mean manual optimization.

like loading model when it actually requires, or dynamically create 
listview with model using component loader or createComponent.


QML is easy and fast when you making small projects. but for complex you 
should thinh HOW code actially works after interpretation.


On 16.12.2013 02:08, Hendrik Borghorst wrote:

What do you mean exactly?

Isn't this exactly what ListView should do automatically which can be
influenced with cacheBuffer? Which by the way works correctly as long as
the listview stays visible.

greetings


Am Montag, den 16.12.2013, 02:05 +0600 schrieb Andrey Kozhevnikov:

load model dynamically?

if you wont preload model before using it can solve many problems.
:)

On 16.12.2013 02:03, Hendrik Borghorst wrote:


Hello,

the problem isn't my delegate. It is quite minimal.

The problem is I think a bug in QML Listview. It goes absolutly crazy if
it is invisible and starts making delegate for around 50% of all items.
This causes the memory to run full.

A workaround I added is

model: visible ? modelVar : null

which works quite nicely. I think this bug could be an upstream qt bug?

greetings

Am Sonntag, den 15.12.2013, 10:01 +0100 schrieb
christopher.l...@thurweb.ch:

Hi Hendrik

Have you seen this? http://qt-project.org/wiki/Performance_tip_Lists

The general advice is to keep the delegates is lightweight as
possible, and to use Loaders for anything needed later (e.g. onClick)

Chris

Zitat von "Hendrik Borghorst" :


Hello folks,

I've got a problem with long lists (~25000 elements). All delegates are
created at once which causes the memory usage to explode beyond the
devices capability.

I already tried setting "cacheBuffer: 0" in SiliciaListView but  it
doesn't change it.

Is the something I'm doing wrong.

You can see the actual page code here:

https://github.com/djselbeck/smpc/blob/master/pages/CurrentPlaylistPage.qml

Shouldn't the delegates be constructed on demand? It is weird because my
old n8 wasn't struggling with qml lists with this size.

greetings and congrats on getting the devices to your customers (I'm
very pleased)






___
SailfishOS.org Devel mailing list

___
SailfishOS.org Devel mailing list



___
SailfishOS.org Devel mailing list


___
SailfishOS.org Devel mailing list

Re: [SailfishDevel] Delegate creation on demand

2013-12-15 Thread Hendrik Borghorst
It is weird if I have to manually optimize something which worked for 2
years on an old Nokia N8 with 128? MB memory. I don't see any reason for
qt to create those delegate items and as I read the documentation of the
qt-project QAbstractListModel is exactly the way to go.

Also there are cases where manual optimization is far less efficient
than tested optimizations done by compilers or good libraries ;) .

Am Montag, den 16.12.2013, 02:14 +0600 schrieb Andrey Kozhevnikov:
> no, i mean manual optimization.
> 
> like loading model when it actually requires, or dynamically create
> listview with model using component loader or createComponent.
> 
> QML is easy and fast when you making small projects. but for complex
> you should thinh HOW code actially works after interpretation.
> 
> On 16.12.2013 02:08, Hendrik Borghorst wrote:
> 
> > What do you mean exactly?
> > 
> > Isn't this exactly what ListView should do automatically which can be
> > influenced with cacheBuffer? Which by the way works correctly as long as
> > the listview stays visible. 
> > 
> > greetings
> > 
> > 
> > Am Montag, den 16.12.2013, 02:05 +0600 schrieb Andrey Kozhevnikov:
> > > load model dynamically?
> > > 
> > > if you wont preload model before using it can solve many problems.
> > > :)
> > > 
> > > On 16.12.2013 02:03, Hendrik Borghorst wrote:
> > > 
> > > > Hello,
> > > > 
> > > > the problem isn't my delegate. It is quite minimal. 
> > > > 
> > > > The problem is I think a bug in QML Listview. It goes absolutly crazy if
> > > > it is invisible and starts making delegate for around 50% of all items.
> > > > This causes the memory to run full.
> > > > 
> > > > A workaround I added is
> > > > 
> > > > model: visible ? modelVar : null
> > > > 
> > > > which works quite nicely. I think this bug could be an upstream qt bug?
> > > > 
> > > > greetings
> > > > 
> > > > Am Sonntag, den 15.12.2013, 10:01 +0100 schrieb
> > > > christopher.l...@thurweb.ch:
> > > > > Hi Hendrik
> > > > > 
> > > > > Have you seen this? http://qt-project.org/wiki/Performance_tip_Lists
> > > > > 
> > > > > The general advice is to keep the delegates is lightweight as  
> > > > > possible, and to use Loaders for anything needed later (e.g. onClick)
> > > > > 
> > > > > Chris
> > > > > 
> > > > > Zitat von "Hendrik Borghorst" :
> > > > > 
> > > > > > Hello folks,
> > > > > > 
> > > > > > I've got a problem with long lists (~25000 elements). All delegates 
> > > > > > are
> > > > > > created at once which causes the memory usage to explode beyond the
> > > > > > devices capability.
> > > > > > 
> > > > > > I already tried setting "cacheBuffer: 0" in SiliciaListView but  it
> > > > > > doesn't change it.
> > > > > > 
> > > > > > Is the something I'm doing wrong.
> > > > > > 
> > > > > > You can see the actual page code here:
> > > > > > 
> > > > > > https://github.com/djselbeck/smpc/blob/master/pages/CurrentPlaylistPage.qml
> > > > > > 
> > > > > > Shouldn't the delegates be constructed on demand? It is weird 
> > > > > > because my
> > > > > > old n8 wasn't struggling with qml lists with this size.
> > > > > > 
> > > > > > greetings and congrats on getting the devices to your customers (I'm
> > > > > > very pleased)
> > > > > > 
> > > > > 
> > > > > 
> > > > 
> > > > ___
> > > > SailfishOS.org Devel mailing list
> > > ___
> > > SailfishOS.org Devel mailing list
> > 
> > 
> > ___
> > SailfishOS.org Devel mailing list
> 
> ___
> SailfishOS.org Devel mailing list



signature.asc
Description: This is a digitally signed message part
___
SailfishOS.org Devel mailing list

Re: [SailfishDevel] Delegate creation on demand

2013-12-15 Thread Andrey Kozhevnikov

you doing it wrong. its all what i see now :)

On 16.12.2013 02:17, Hendrik Borghorst wrote:

It is weird if I have to manually optimize something which worked for 2
years on an old Nokia N8 with 128? MB memory. I don't see any reason for
qt to create those delegate items and as I read the documentation of the
qt-project QAbstractListModel is exactly the way to go.

Also there are cases where manual optimization is far less efficient
than tested optimizations done by compilers or good libraries ;) .

Am Montag, den 16.12.2013, 02:14 +0600 schrieb Andrey Kozhevnikov:

no, i mean manual optimization.

like loading model when it actually requires, or dynamically create
listview with model using component loader or createComponent.

QML is easy and fast when you making small projects. but for complex
you should thinh HOW code actially works after interpretation.

On 16.12.2013 02:08, Hendrik Borghorst wrote:


What do you mean exactly?

Isn't this exactly what ListView should do automatically which can be
influenced with cacheBuffer? Which by the way works correctly as long as
the listview stays visible.

greetings


Am Montag, den 16.12.2013, 02:05 +0600 schrieb Andrey Kozhevnikov:

load model dynamically?

if you wont preload model before using it can solve many problems.
:)

On 16.12.2013 02:03, Hendrik Borghorst wrote:


Hello,

the problem isn't my delegate. It is quite minimal.

The problem is I think a bug in QML Listview. It goes absolutly crazy if
it is invisible and starts making delegate for around 50% of all items.
This causes the memory to run full.

A workaround I added is

model: visible ? modelVar : null

which works quite nicely. I think this bug could be an upstream qt bug?

greetings

Am Sonntag, den 15.12.2013, 10:01 +0100 schrieb
christopher.l...@thurweb.ch:

Hi Hendrik

Have you seen this? http://qt-project.org/wiki/Performance_tip_Lists

The general advice is to keep the delegates is lightweight as
possible, and to use Loaders for anything needed later (e.g. onClick)

Chris

Zitat von "Hendrik Borghorst" :


Hello folks,

I've got a problem with long lists (~25000 elements). All delegates are
created at once which causes the memory usage to explode beyond the
devices capability.

I already tried setting "cacheBuffer: 0" in SiliciaListView but  it
doesn't change it.

Is the something I'm doing wrong.

You can see the actual page code here:

https://github.com/djselbeck/smpc/blob/master/pages/CurrentPlaylistPage.qml

Shouldn't the delegates be constructed on demand? It is weird because my
old n8 wasn't struggling with qml lists with this size.

greetings and congrats on getting the devices to your customers (I'm
very pleased)




___
SailfishOS.org Devel mailing list

___
SailfishOS.org Devel mailing list


___
SailfishOS.org Devel mailing list

___
SailfishOS.org Devel mailing list



___
SailfishOS.org Devel mailing list


___
SailfishOS.org Devel mailing list

Re: [SailfishDevel] Delegate creation on demand

2013-12-15 Thread Hendrik Borghorst
Than if it is so clear could you be so nice and point me to some
documentation?

Am Montag, den 16.12.2013, 02:19 +0600 schrieb Andrey Kozhevnikov:
> you doing it wrong. its all what i see now :)
> 
> On 16.12.2013 02:17, Hendrik Borghorst wrote:
> 
> > It is weird if I have to manually optimize something which worked for 2
> > years on an old Nokia N8 with 128? MB memory. I don't see any reason for
> > qt to create those delegate items and as I read the documentation of the
> > qt-project QAbstractListModel is exactly the way to go.
> > 
> > Also there are cases where manual optimization is far less efficient
> > than tested optimizations done by compilers or good libraries ;) .
> > 
> > Am Montag, den 16.12.2013, 02:14 +0600 schrieb Andrey Kozhevnikov:
> > > no, i mean manual optimization.
> > > 
> > > like loading model when it actually requires, or dynamically create
> > > listview with model using component loader or createComponent.
> > > 
> > > QML is easy and fast when you making small projects. but for complex
> > > you should thinh HOW code actially works after interpretation.
> > > 
> > > On 16.12.2013 02:08, Hendrik Borghorst wrote:
> > > 
> > > > What do you mean exactly?
> > > > 
> > > > Isn't this exactly what ListView should do automatically which can be
> > > > influenced with cacheBuffer? Which by the way works correctly as long as
> > > > the listview stays visible. 
> > > > 
> > > > greetings
> > > > 
> > > > 
> > > > Am Montag, den 16.12.2013, 02:05 +0600 schrieb Andrey Kozhevnikov:
> > > > > load model dynamically?
> > > > > 
> > > > > if you wont preload model before using it can solve many problems.
> > > > > :)
> > > > > 
> > > > > On 16.12.2013 02:03, Hendrik Borghorst wrote:
> > > > > 
> > > > > > Hello,
> > > > > > 
> > > > > > the problem isn't my delegate. It is quite minimal. 
> > > > > > 
> > > > > > The problem is I think a bug in QML Listview. It goes absolutly 
> > > > > > crazy if
> > > > > > it is invisible and starts making delegate for around 50% of all 
> > > > > > items.
> > > > > > This causes the memory to run full.
> > > > > > 
> > > > > > A workaround I added is
> > > > > > 
> > > > > > model: visible ? modelVar : null
> > > > > > 
> > > > > > which works quite nicely. I think this bug could be an upstream qt 
> > > > > > bug?
> > > > > > 
> > > > > > greetings
> > > > > > 
> > > > > > Am Sonntag, den 15.12.2013, 10:01 +0100 schrieb
> > > > > > christopher.l...@thurweb.ch:
> > > > > > > Hi Hendrik
> > > > > > > 
> > > > > > > Have you seen this? 
> > > > > > > http://qt-project.org/wiki/Performance_tip_Lists
> > > > > > > 
> > > > > > > The general advice is to keep the delegates is lightweight as  
> > > > > > > possible, and to use Loaders for anything needed later (e.g. 
> > > > > > > onClick)
> > > > > > > 
> > > > > > > Chris
> > > > > > > 
> > > > > > > Zitat von "Hendrik Borghorst" :
> > > > > > > 
> > > > > > > > Hello folks,
> > > > > > > > 
> > > > > > > > I've got a problem with long lists (~25000 elements). All 
> > > > > > > > delegates are
> > > > > > > > created at once which causes the memory usage to explode beyond 
> > > > > > > > the
> > > > > > > > devices capability.
> > > > > > > > 
> > > > > > > > I already tried setting "cacheBuffer: 0" in SiliciaListView but 
> > > > > > > >  it
> > > > > > > > doesn't change it.
> > > > > > > > 
> > > > > > > > Is the something I'm doing wrong.
> > > > > > > > 
> > > > > > > > You can see the actual page code here:
> > > > > > > > 
> > > > > > > > https://github.com/djselbeck/smpc/blob/master/pages/CurrentPlaylistPage.qml
> > > > > > > > 
> > > > > > > > Shouldn't the delegates be constructed on demand? It is weird 
> > > > > > > > because my
> > > > > > > > old n8 wasn't struggling with qml lists with this size.
> > > > > > > > 
> > > > > > > > greetings and congrats on getting the devices to your customers 
> > > > > > > > (I'm
> > > > > > > > very pleased)
> > > > > > > > 
> > > > > > > 
> > > > > > ___
> > > > > > SailfishOS.org Devel mailing list
> > > > > ___
> > > > > SailfishOS.org Devel mailing list
> > > > 
> > > > ___
> > > > SailfishOS.org Devel mailing list
> > > ___
> > > SailfishOS.org Devel mailing list
> > 
> > 
> > ___
> > SailfishOS.org Devel mailing list
> 
> ___
> SailfishOS.org Devel mailing list



signature.asc
Description: This is a digitally signed message part
___
SailfishOS.org Devel mailing list

Re: [SailfishDevel] Delegate creation on demand

2013-12-15 Thread Andrey Kozhevnikov

start with "Dynamic Object Management"

On 16.12.2013 02:21, Hendrik Borghorst wrote:

Than if it is so clear could you be so nice and point me to some
documentation?

Am Montag, den 16.12.2013, 02:19 +0600 schrieb Andrey Kozhevnikov:

you doing it wrong. its all what i see now :)

On 16.12.2013 02:17, Hendrik Borghorst wrote:


It is weird if I have to manually optimize something which worked for 2
years on an old Nokia N8 with 128? MB memory. I don't see any reason for
qt to create those delegate items and as I read the documentation of the
qt-project QAbstractListModel is exactly the way to go.

Also there are cases where manual optimization is far less efficient
than tested optimizations done by compilers or good libraries ;) .

Am Montag, den 16.12.2013, 02:14 +0600 schrieb Andrey Kozhevnikov:

no, i mean manual optimization.

like loading model when it actually requires, or dynamically create
listview with model using component loader or createComponent.

QML is easy and fast when you making small projects. but for complex
you should thinh HOW code actially works after interpretation.

On 16.12.2013 02:08, Hendrik Borghorst wrote:


What do you mean exactly?

Isn't this exactly what ListView should do automatically which can be
influenced with cacheBuffer? Which by the way works correctly as long as
the listview stays visible.

greetings


Am Montag, den 16.12.2013, 02:05 +0600 schrieb Andrey Kozhevnikov:

load model dynamically?

if you wont preload model before using it can solve many problems.
:)

On 16.12.2013 02:03, Hendrik Borghorst wrote:


Hello,

the problem isn't my delegate. It is quite minimal.

The problem is I think a bug in QML Listview. It goes absolutly crazy if
it is invisible and starts making delegate for around 50% of all items.
This causes the memory to run full.

A workaround I added is

model: visible ? modelVar : null

which works quite nicely. I think this bug could be an upstream qt bug?

greetings

Am Sonntag, den 15.12.2013, 10:01 +0100 schrieb
christopher.l...@thurweb.ch:

Hi Hendrik

Have you seen this? http://qt-project.org/wiki/Performance_tip_Lists

The general advice is to keep the delegates is lightweight as
possible, and to use Loaders for anything needed later (e.g. onClick)

Chris

Zitat von "Hendrik Borghorst" :


Hello folks,

I've got a problem with long lists (~25000 elements). All delegates are
created at once which causes the memory usage to explode beyond the
devices capability.

I already tried setting "cacheBuffer: 0" in SiliciaListView but  it
doesn't change it.

Is the something I'm doing wrong.

You can see the actual page code here:

https://github.com/djselbeck/smpc/blob/master/pages/CurrentPlaylistPage.qml

Shouldn't the delegates be constructed on demand? It is weird because my
old n8 wasn't struggling with qml lists with this size.

greetings and congrats on getting the devices to your customers (I'm
very pleased)


___
SailfishOS.org Devel mailing list

___
SailfishOS.org Devel mailing list

___
SailfishOS.org Devel mailing list

___
SailfishOS.org Devel mailing list


___
SailfishOS.org Devel mailing list

___
SailfishOS.org Devel mailing list



___
SailfishOS.org Devel mailing list


___
SailfishOS.org Devel mailing list

Re: [SailfishDevel] Delegate creation on demand

2013-12-15 Thread Robin Burchell
Can you please provide a minimal test case (i.e. ideally a single QML file, 
usable with qmlscene) demonstrating your problem?

Please see http://sscce.org/

On 15 Dec 2013, at 21:03, Hendrik Borghorst  wrote:

> Hello,
> 
> the problem isn't my delegate. It is quite minimal. 
> 
> The problem is I think a bug in QML Listview. It goes absolutly crazy if
> it is invisible and starts making delegate for around 50% of all items.
> This causes the memory to run full.
> 
> A workaround I added is
> 
> model: visible ? modelVar : null
> 
> which works quite nicely. I think this bug could be an upstream qt bug?

> 
> greetings
> 
> Am Sonntag, den 15.12.2013, 10:01 +0100 schrieb
> christopher.l...@thurweb.ch:
>> Hi Hendrik
>> 
>> Have you seen this? http://qt-project.org/wiki/Performance_tip_Lists
>> 
>> The general advice is to keep the delegates is lightweight as  
>> possible, and to use Loaders for anything needed later (e.g. onClick)
>> 
>> Chris
>> 
>> Zitat von "Hendrik Borghorst" :
>> 
>>> Hello folks,
>>> 
>>> I've got a problem with long lists (~25000 elements). All delegates are
>>> created at once which causes the memory usage to explode beyond the
>>> devices capability.
>>> 
>>> I already tried setting "cacheBuffer: 0" in SiliciaListView but  it
>>> doesn't change it.
>>> 
>>> Is the something I'm doing wrong.
>>> 
>>> You can see the actual page code here:
>>> 
>>> https://github.com/djselbeck/smpc/blob/master/pages/CurrentPlaylistPage.qml
>>> 
>>> Shouldn't the delegates be constructed on demand? It is weird because my
>>> old n8 wasn't struggling with qml lists with this size.
>>> 
>>> greetings and congrats on getting the devices to your customers (I'm
>>> very pleased)
>>> 
>> 
>> 
>> 
>> 
> 
> ___
> SailfishOS.org Devel mailing list

___
SailfishOS.org Devel mailing list


Re: [SailfishDevel] Delegate creation on demand

2013-12-15 Thread Hendrik Borghorst
Sure,

This example I've just created and it does exactly what I want to show.

greetings and thanks for your support

There are 2 buttons, one populates the model with 25000 simple items. 

The second one pushes a page above the page with listview. After the
push you can see the ListView creating lots of delegates in console.log

PS.: I've not tested it with qmlscene but as an application
(modeltext.tar.xz) on real device.


Am Sonntag, den 15.12.2013, 20:25 + schrieb Robin Burchell:
> Can you please provide a minimal test case (i.e. ideally a single QML file, 
> usable with qmlscene) demonstrating your problem?
> 
> Please see http://sscce.org/
> 
> On 15 Dec 2013, at 21:03, Hendrik Borghorst  
> wrote:
> 
> > Hello,
> > 
> > the problem isn't my delegate. It is quite minimal. 
> > 
> > The problem is I think a bug in QML Listview. It goes absolutly crazy if
> > it is invisible and starts making delegate for around 50% of all items.
> > This causes the memory to run full.
> > 
> > A workaround I added is
> > 
> > model: visible ? modelVar : null
> > 
> > which works quite nicely. I think this bug could be an upstream qt bug?
> 
> > 
> > greetings
> > 
> > Am Sonntag, den 15.12.2013, 10:01 +0100 schrieb
> > christopher.l...@thurweb.ch:
> >> Hi Hendrik
> >> 
> >> Have you seen this? http://qt-project.org/wiki/Performance_tip_Lists
> >> 
> >> The general advice is to keep the delegates is lightweight as  
> >> possible, and to use Loaders for anything needed later (e.g. onClick)
> >> 
> >> Chris
> >> 
> >> Zitat von "Hendrik Borghorst" :
> >> 
> >>> Hello folks,
> >>> 
> >>> I've got a problem with long lists (~25000 elements). All delegates are
> >>> created at once which causes the memory usage to explode beyond the
> >>> devices capability.
> >>> 
> >>> I already tried setting "cacheBuffer: 0" in SiliciaListView but  it
> >>> doesn't change it.
> >>> 
> >>> Is the something I'm doing wrong.
> >>> 
> >>> You can see the actual page code here:
> >>> 
> >>> https://github.com/djselbeck/smpc/blob/master/pages/CurrentPlaylistPage.qml
> >>> 
> >>> Shouldn't the delegates be constructed on demand? It is weird because my
> >>> old n8 wasn't struggling with qml lists with this size.
> >>> 
> >>> greetings and congrats on getting the devices to your customers (I'm
> >>> very pleased)
> >>> 
> >> 
> >> 
> >> 
> >> 
> > 
> > ___
> > SailfishOS.org Devel mailing list
> 
> ___
> SailfishOS.org Devel mailing list

import QtQuick 2.0
import Sailfish.Silica 1.0

ApplicationWindow {
Component {
id: mainPage
Page {
SilicaListView {
id: listView
anchors {
top: parent.top
bottom: buttonRow.top
left: parent.left
right: parent.right
}

delegate: Component {
ListItem {
Row {
Label {
text: index
}
Label {
text: value
}
}
Component.onCompleted: {
console.debug("Created delegate: " + index)
}
}
}
}
Row {
id: buttonRow
anchors {
bottom: parent.bottom
right: parent.right
left: parent.left
}

Button {
text: "populate"
onClicked: {

for (var i = 0; i <= 25000; i++) {
// Populate an model with some demo data
console.debug("populating: " + i)
testModel.append({
 index: i,
 value: "Some text"
 })
}
listView.model = testModel
}
}
/** The moment you press on this button
  you can see console.log with delegate creations
  */
Button {
text: "new page"
onClicked: {
pageStack.push(emptyPage)
}
}
}

// Empty model until populated
ListModel {
id: testModel
}
}
}

// Just an empty page for demonstration
Component {
id: emptyPage
Page {
}
}

initialPage: mainPage
}


modeltest.tar.xz
Description: application/xz-compressed-tar


signature.asc
Descripti

Re: [SailfishDevel] working on apps?

2013-12-15 Thread Nicola De Filippo
Hi,

Il giorno 15/dic/2013, alle ore 19:06, David Greaves  
ha scritto:

> On 15/12/13 17:41, AL13N wrote:
>>> Currency Converter: https://github.com/tanghus/currency-converter-qml
>>> Kitchen Timer: https://github.com/tanghus/kitchen-timer-qml
>>> 
>>> The capcha for your site is ridiculous, so posting it here instead :)
>> 
>> It's not my site (it's for embedded linux), but that captcha _is_
>> ridiculous... i couldn't answer one question, after dozens of reloads, i
>> ended up researching the Linus Torvalds question and cycle the captcha
>> until i got that one... :-(
>> 
>> Since we don't have anything yet, this is a place where we can put some
>> documentation until there might be a better place... though, otoh, since
>> this is about embedded Linux, it's not exactly a wrong place either...
> 
> There's always:
> 
>  https://wiki.merproject.org/wiki/Sailfish
> 
> Which has been around since Mar 2013 :)

In fact, I'm waiting for the device to try Alice on the real device and then 
publish it 
   N.
___
SailfishOS.org Devel mailing list


Re: [SailfishDevel] Delegate creation on demand

2013-12-15 Thread christopher . lamb

Hi Hendrik

My feeling is also that you have stumbled upon a bug.

Your update with the visible = false crossed mine.

My understanding was that all delegates are created when the ListView  
is created / Loaded. I see no reason at all why the ListView should go  
on a creation spree when it becomes INVISIBLE. That seems counter  
intuitive to me.


It has been suggested that you use dynamic loading, but I don't think  
that helps your problem. Just to be clear, I have used that technique  
successfully in two ways.


1) in my app Landed overall startup time was poor. One of the reasons  
was that all pages were being created on startup, and one was loading  
the phone's ContactModel. Given that the user may never actually get  
as far as the Page containing the ContactModel, I decided it would be  
better to dynamically load the ContactModel if and when that page  
becomes visible. So the app now starts fast, with the slight downside  
that if a user choses to access the phone's contacts, he needs to wait  
at at that point for the ContactModel to load.


2) Once the ContactModel was loaded (with several hundred contacts),  
scrolling in the ListView was terrible. The solution here was to make  
the delegate as lightweight as possible, and to dynamically load all  
the bits required when the delegate is clicked.


However from the behaviour you describe, none of that will help you. I  
need to do some thinking ...


bis bald

Chris

Zitat von "Hendrik Borghorst" :


Hello,

the problem isn't my delegate. It is quite minimal.

The problem is I think a bug in QML Listview. It goes absolutly crazy if
it is invisible and starts making delegate for around 50% of all items.
This causes the memory to run full.

A workaround I added is

model: visible ? modelVar : null

which works quite nicely. I think this bug could be an upstream qt bug?

greetings

Am Sonntag, den 15.12.2013, 10:01 +0100 schrieb
christopher.l...@thurweb.ch:

Hi Hendrik

Have you seen this? http://qt-project.org/wiki/Performance_tip_Lists

The general advice is to keep the delegates is lightweight as
possible, and to use Loaders for anything needed later (e.g. onClick)

Chris

Zitat von "Hendrik Borghorst" :

> Hello folks,
>
> I've got a problem with long lists (~25000 elements). All delegates are
> created at once which causes the memory usage to explode beyond the
> devices capability.
>
> I already tried setting "cacheBuffer: 0" in SiliciaListView but  it
> doesn't change it.
>
> Is the something I'm doing wrong.
>
> You can see the actual page code here:
>
>  
https://github.com/djselbeck/smpc/blob/master/pages/CurrentPlaylistPage.qml

>
> Shouldn't the delegates be constructed on demand? It is weird because my
> old n8 wasn't struggling with qml lists with this size.
>
> greetings and congrats on getting the devices to your customers (I'm
> very pleased)
>











___
SailfishOS.org Devel mailing list


Re: [SailfishDevel] working on apps?

2013-12-15 Thread Kimmo Lindholm
Thomas, I pulled your kitchen-timer, built and deployed as rpm, and tested it 
on device, it gives me just white screen when started.

-kimmo

-Original Message-
From: devel-boun...@lists.sailfishos.org 
[mailto:devel-boun...@lists.sailfishos.org] On Behalf Of Thomas Tanghus
Sent: Sunday, December 15, 2013 8:49 AM
To: Sailfish OS Developers
Subject: Re: [SailfishDevel] working on apps?

Currency Converter: https://github.com/tanghus/currency-converter-qml
Kitchen Timer: https://github.com/tanghus/kitchen-timer-qml

The capcha for your site is ridiculous, so posting it here instead :)

On Saturday 14 December 2013 11:41 AL13N wrote:
> if there are people who are working on apps, and want to let it know, 
> so that no other devs will waste time making the same apps, you can 
> add these
> here:
> 
> http://elinux.org/Jolla
> 
> in the appriopriate section.
> 
> Thanks!
> 
> ___
> SailfishOS.org Devel mailing list

--
Med venlig hilsen / Best Regards

Thomas Tanghus
___
SailfishOS.org Devel mailing list
___
SailfishOS.org Devel mailing list


[SailfishDevel] Using Python 3 and PyOtherSide repository on Sailfish device

2013-12-15 Thread Roberto Colistete Jr.

Em 30-09-2013 09:40, Thomas Perl escreveu:

The rest of this mail deals with PyOtherSide:

It's available in the mer-python3 repository:
https://build.merproject.org/project/show?project=mer-python3

In the sb2 target and on a device, you can add that repo using:
zypper ar 
http://repo.merproject.org/obs/mer-python3/latest_armv7hl/mer-python3.repo


Hi,

First of all, bravo, Jolla sailors, Sailfish OS is fantastic ! Even 
using it on Nokia N9.


I am trying Python in Sailfish (port) on Nokia N9 (yeah, I live in 
Brazil so a Jolla smartphone will take time to be here) :

http://talk.maemo.org/showpost.php?p=1396818&postcount=51
http://talk.maemo.org/showthread.php?t=92036

After adding mer-python3 repository on device (Jolla smartphone or 
Nokia N9 with Sailfish port) :
# zypper ar 
http://repo.merproject.org/obs/mer-python3/latest_armv7hl/mer-python3.repo

# zypper ref
which is not signed (zypper ref shows "file 'repomd.xml' of repository 
'Python 3 for Mer (latest_armv7hl)' is not signed", so I confirm t), the 
Jolla Store can't install any software (it shows "Waiting" forever when 
trying to install any chosen software).


A temporary solution is simply installing Python3 and PyOtherSide :
# zypper in python3-base pyotherside-qml-plugin-python3-qt5
then removing the repository :
# zypper rr mer-python3
# zypper ref
So Jolla Store works again.

Any suggestion to have mer-python3 or any other Mer COBS 
repositories (e.g., mine 
http://repo.merproject.org/obs/home:/rcolistete/latest_armv7hl/) enabled 
and also use Jolla Store ?


Is there another recommended method to add a repository in Sailfish 
OS ?


Best regards,

Roberto
___
SailfishOS.org Devel mailing list


Re: [SailfishDevel] working on apps?

2013-12-15 Thread AL13N
> On 15/12/13 17:41, AL13N wrote:
>>> Currency Converter: https://github.com/tanghus/currency-converter-qml
>>> Kitchen Timer: https://github.com/tanghus/kitchen-timer-qml
>>>
>>> The capcha for your site is ridiculous, so posting it here instead :)
>>
>> It's not my site (it's for embedded linux), but that captcha _is_
>> ridiculous... i couldn't answer one question, after dozens of reloads, i
>> ended up researching the Linus Torvalds question and cycle the captcha
>> until i got that one... :-(
>>
>> Since we don't have anything yet, this is a place where we can put some
>> documentation until there might be a better place... though, otoh, since
>> this is about embedded Linux, it's not exactly a wrong place either...
>
> There's always:
>
>   https://wiki.merproject.org/wiki/Sailfish
>
> Which has been around since Mar 2013 :)

yes, the reason we didn't take such a wiki, is due to the Jolla hardware
thing, while sailfish will be used on alot of hardware, Jolla was
something different, and we needed it more for gathering technical data
(like the I²C bus)

___
SailfishOS.org Devel mailing list

Re: [SailfishDevel] Delegate creation on demand

2013-12-15 Thread Chris Adams
Hi,

It seems like the ListItem delegate relies on implicit height for its geometry. 
 When the empty page is pushed, the delegates get their height set to zero, 
which causes the listview to create more delegates to fit into the visible 
area.  Since any finite height divided by zero is infinity, it attempts to 
create an infinite amount of delegates (or until it runs out of model data).

The workaround is to do something like this:

delegate: Component {
ListItem {
height: row.height > 5 ? row.height : 5 // don't rely on implicit 
height for sizing if it goes too small
Row {
id: row
Label {
text: index
}
Label {
text: value
}
}
Component.onCompleted: {
   console.debug("Created delegate: " + index)
}
}
}

We should definitely fix this issue in Silica to ensure that the minimal 
delegate height is clamped to 1 perhaps (well, this is probably not the right 
solution either, we'll have to think about how to do it properly).
In the meantime, please try using the workaround.

Cheers,
Chris.


From: devel-boun...@lists.sailfishos.org [devel-boun...@lists.sailfishos.org] 
on behalf of Hendrik Borghorst [hendrikborgho...@gmail.com]
Sent: Monday, December 16, 2013 6:49 AM
To: devel@lists.sailfishos.org
Subject: Re: [SailfishDevel] Delegate creation on demand

Sure,

This example I've just created and it does exactly what I want to show.

greetings and thanks for your support

There are 2 buttons, one populates the model with 25000 simple items.

The second one pushes a page above the page with listview. After the
push you can see the ListView creating lots of delegates in console.log

PS.: I've not tested it with qmlscene but as an application
(modeltext.tar.xz) on real device.


Am Sonntag, den 15.12.2013, 20:25 + schrieb Robin Burchell:
> Can you please provide a minimal test case (i.e. ideally a single QML file, 
> usable with qmlscene) demonstrating your problem?
>
> Please see http://sscce.org/
>
> On 15 Dec 2013, at 21:03, Hendrik Borghorst  
> wrote:
>
> > Hello,
> >
> > the problem isn't my delegate. It is quite minimal.
> >
> > The problem is I think a bug in QML Listview. It goes absolutly crazy if
> > it is invisible and starts making delegate for around 50% of all items.
> > This causes the memory to run full.
> >
> > A workaround I added is
> >
> > model: visible ? modelVar : null
> >
> > which works quite nicely. I think this bug could be an upstream qt bug?
>
> >
> > greetings
> >
> > Am Sonntag, den 15.12.2013, 10:01 +0100 schrieb
> > christopher.l...@thurweb.ch:
> >> Hi Hendrik
> >>
> >> Have you seen this? http://qt-project.org/wiki/Performance_tip_Lists
> >>
> >> The general advice is to keep the delegates is lightweight as
> >> possible, and to use Loaders for anything needed later (e.g. onClick)
> >>
> >> Chris
> >>
> >> Zitat von "Hendrik Borghorst" :
> >>
> >>> Hello folks,
> >>>
> >>> I've got a problem with long lists (~25000 elements). All delegates are
> >>> created at once which causes the memory usage to explode beyond the
> >>> devices capability.
> >>>
> >>> I already tried setting "cacheBuffer: 0" in SiliciaListView but  it
> >>> doesn't change it.
> >>>
> >>> Is the something I'm doing wrong.
> >>>
> >>> You can see the actual page code here:
> >>>
> >>> https://github.com/djselbeck/smpc/blob/master/pages/CurrentPlaylistPage.qml
> >>>
> >>> Shouldn't the delegates be constructed on demand? It is weird because my
> >>> old n8 wasn't struggling with qml lists with this size.
> >>>
> >>> greetings and congrats on getting the devices to your customers (I'm
> >>> very pleased)
> >>>
> >>
> >>
> >>
> >>
> >
> > ___
> > SailfishOS.org Devel mailing list
>
> ___
> SailfishOS.org Devel mailing list

___
SailfishOS.org Devel mailing list


[SailfishDevel] Using Python 3 and PyOtherSide repository on Sailfish device : one solution

2013-12-15 Thread Roberto Colistete Jr.

Hi,

Ops, I think I've found the solution, the "-G" (--no-gpgcheck, 
Disable GPG verification for this repository) is needed :
# zypper ar -G 
http://repo.merproject.org/obs/mer-python3/latest_armv7hl/mer-python3.repo
So this and other Mer COBS repositories can remain enabled and Jolla 
Store works (for installing softwares).


But is there any other way to add repositories in Sailfish ?

Repositories added with "zypper ar" are listed by "zypper lr", but 
no "ssu lr".


Regards,

Roberto


 Mensagem original 
Assunto:Using Python 3 and PyOtherSide repository on Sailfish device
Data:   Sun, 15 Dec 2013 20:11:48 -0200
De: Roberto Colistete Jr. 
Para:   Thomas Perl 
CC: devel@lists.sailfishos.org 



Em 30-09-2013 09:40, Thomas Perl escreveu:

The rest of this mail deals with PyOtherSide:

It's available in the mer-python3 repository:
https://build.merproject.org/project/show?project=mer-python3

In the sb2 target and on a device, you can add that repo using:
zypper ar 
http://repo.merproject.org/obs/mer-python3/latest_armv7hl/mer-python3.repo


Hi,

First of all, bravo, Jolla sailors, Sailfish OS is fantastic ! Even
using it on Nokia N9.

I am trying Python in Sailfish (port) on Nokia N9 (yeah, I live in
Brazil so a Jolla smartphone will take time to be here) :
http://talk.maemo.org/showpost.php?p=1396818&postcount=51
http://talk.maemo.org/showthread.php?t=92036

After adding mer-python3 repository on device (Jolla smartphone or
Nokia N9 with Sailfish port) :
# zypper ar
http://repo.merproject.org/obs/mer-python3/latest_armv7hl/mer-python3.repo
# zypper ref
which is not signed (zypper ref shows "file 'repomd.xml' of repository
'Python 3 for Mer (latest_armv7hl)' is not signed", so I confirm t), the
Jolla Store can't install any software (it shows "Waiting" forever when
trying to install any chosen software).

A temporary solution is simply installing Python3 and PyOtherSide :
# zypper in python3-base pyotherside-qml-plugin-python3-qt5
then removing the repository :
# zypper rr mer-python3
# zypper ref
So Jolla Store works again.

Any suggestion to have mer-python3 or any other Mer COBS
repositories (e.g., mine
http://repo.merproject.org/obs/home:/rcolistete/latest_armv7hl/) enabled
and also use Jolla Store ?

Is there another recommended method to add a repository in Sailfish
OS ?

Best regards,

Roberto




___
SailfishOS.org Devel mailing list