[Interest] Qt 5 and filesystem

Jason H scorp1us at yahoo.com
Fri Jan 4 16:17:46 CET 2013


I could be mistaken, but isn't the solution just as simple as using a QGraphicsWidgetProxy for a QFileDialog and exporting that to QML as a component. It should be like 10 lines of code, no?





________________________________
 From: Bo Thorsen <bo at fioniasoftware.dk>
To: Stéphane Fabry <sf at xris.eu> 
Cc: interest at qt-project.org 
Sent: Friday, January 4, 2013 4:09 AM
Subject: Re: [Interest] Qt 5 and filesystem
 

Hi Stéphane,

Yes exactly, the problem is that QML is young. I expect that the
      capabilities will expand quite a lot over the coming years, and
      file handling is an obvious place for improvements. Qt (the C++
      parts) had over 16 years to develop into the current system, QML
      is an infant compared to it.

If anyone on this list is looking for a hobby project to work on,
      this might be a great project for you. It's interesting,
      contained, and much needed. Those are three very good starting
      points for an OSS project.

Bo.

Den 04-01-2013 09:41, Stéphane Fabry skrev:

Thanks for your replies,
>
>I understand for dialogs, their are sometimes drawed using
        QWidgets where native do not provide them.
>
>Ok for C++ solution, that's not that complicated, but it is
        still some work you do not need to do with QWidgets.
>But Qt5 is still young, maybe we could have such API in Core in
        the future, with QML element being able to display that  stuff
        (filedialog, treeview, ...) - some QML desktop component maybe
        (but at the moment those are still bound to QtWidgets...)
>
>Best Regards,
>
>Stéphane
>
>
>
Le 04-01-13 07:52, Bo Thorsen a écrit :
>
>Дмитрий Козлов is correct. You have to write C++ for this. The reason is that there is no javascript framework available to you, and JS as a language is almost completely stripped of features.
>>
>>In your case, you are trying to do stuff with files. That's
          one case where you are going to be disappointed. There is no
          file handling available in QML/JS at all. Yes, there are a few
          models available (like FolderListModel), but simple file
          handling isn't there.
>>
>>The dialogs can't be moved to QtGui because there are
          implementations that use the Qt widgets. Not all systems
          provide a file dialog that Qt can use.
>>
>>You could find a javascript framework and use this instead.
          But it's probably easier for you to write and deploy C++ based
          Qt code. Make a simple class and export what you need to QML
          with it.
>>
>>Bo.
>>
>>Den 03-01-2013 22:39, Дмитрий Козлов skrev:
>>
>>Most likely, you'll have to write on C++ your component. You also can use FolderListModel (http://doc.qt.digia.com/qt/qml-folderlistmodel.html).
>>>
>>>For example, for my needs I made this:
>>>http://pastebin.com/BSPF3sBw
>>>http://pastebin.com/sxwCb3e5
>>>
>>>
>>>Четверг, 3 января 2013, 21:54 +01:00 от Stéphane Fabry <sf at xris.eu>:
>>>
>>>Hello,
>>>>
>>>>Let's say I'd like to make a desktop application with
                  Qt5 and QtQuick2, the new era :)
>>>>
>>>>How can I simply prompt a file dialog, or display in
                  my QML filesystem entries ?
>>>>Both QFileDialog and QFileSystemModel are still in
                  QtWidget module :(
>>>>I think they should go in QtGui.
>>>>
>>>>
>>>>-- 
>>>>Stéphane Fabry
>>>>
>>>>
>>>>_______________________________________________
>>>>Interest mailing list
>>>>Interest at qt-project.org
>>>>http://lists.qt-project.org/mailman/listinfo/interest
>>>>
>>>>
>>>
>>>
>>>_______________________________________________
Interest mailing list Interest at qt-project.org http://lists.qt-project.org/mailman/listinfo/interest 
>>
>>
>>Bo Thorsen. -- 
Fionia Software - Qt experts for hire.
>


Bo Thorsen. -- 
Fionia Software - Qt experts for hire.
_______________________________________________
Interest mailing list
Interest at qt-project.org
http://lists.qt-project.org/mailman/listinfo/interest
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20130104/669bad6c/attachment.html>


More information about the Interest mailing list