Re: [Qt-creator] Quick test or scratch-pad mode in qtc?

2018-12-22 Thread Jeandet Alexis
Le samedi 22 décembre 2018 à 17:13 +0100, André Hartmann a écrit :
> Hi Alexis,
> 
>  > I was wondering if this would be totally stupid to have a mode in
> QTC
>  > were we could code in a single source with no Build System setup?
> [...]
>  > is so convenient to just start writing code without any setup.
> 
> Sounds good.
> 
>  > But this has many drawbacks like, no or almost no completion, no
> debug
>  > and needs internet.
> 
> So may I ask what your goal is? Is it:
> 
> * Proof that your code compiles?
   It depends what you mean here, it can be to check "can I write
this?" like "is auto here allowed?" Sometime also it is also good
to be able to check if feature X works on compiler Y.
> * Run a small (console) application?
   nope
> * Look at the generated assembly output?
sometime to check what is evaluated at build time 
-> usually this is more to focus on a smaller and simpler code to solve
some problems.For example I was working on this library:
https://github.com/jeandet/TimeSeries/blob/master/include/TimeSeries.hI
had to test few things alone (to avoid brain overheat ;)) like- how
to use CRTP to compose classes with abstract behaviours- how to
make a custom iterator which yield a fake value 
To be more general, when I face an issue and feel  that my code is too
big to reason about something, I just extract the few classes I want to
focus on and work on Coliru.Or also before I start something I do some
tests on coliru if I'm not sure the concept works.
> In principle, one could think of a "scratch" wizard, that
> 
> * Creates a project with a unique name like
>"QTC-Scatch-2018-12-22-17-08"
> * Uses qmake as build system
> * Uses the default "desktop" kit with it's Qt version
>and compiler
> * Adds a main.cpp and opens it in the editor
> 
> You could than choose other compilers through the usual Projects
> mode,
> build, run and debug your project. Other compiler options could be
> set 
> in the Project .pro file.
> 
> That would reduce the setup to two or three clicks and looks simple 
> enough to be integrated without big effort.
> 
> What do you think?
Yes that would definitely speed up things and guess this wouldn't ask
too much work.In the future that would be awesome to get closer to
Coliru and Godblot; get rid of qmake and just set the cpp compiler in a
drop down menu.The issue with QTC is that you can only switch between
kits. Being able to just switch the compiler from the editor would be
nice allow to both check compiler capability and sometime get better
error messages.
> Best regards,André
> 
> Am 22.12.18 um 12:12 schrieb Jeandet Alexis:
> > Hello,
> > 
> > I was wondering if this would be totally stupid to have a mode in
> > QTC
> > were we could code in a single source with no Build System setup?
> > I always go to websites like coliru, godbolt, wandbox,... to do
> > some
> > tests(test concepts, see if I can template something,...) because
> > this
> > is so convenient to just start writing code without any setup. But
> > this
> > has many drawbacks like, no or almost no completion, no debug and
> > needs
> > internet.
> > 
> > In QTC I would easily see a section in welcome page "scratch-pad"
> > with
> > previous ones and a button to create a new one. I don't think we
> > should
> > care about file location or any setup, source files could be stored
> > in
> > QTC user data folder. Maybe we could just switch among available
> > compilers and set manually compile args like godbolt.
> > 
> > Am I the only one who miss this feature?
> > If no I will definitely open a BR.
> > 
> > Best regards and happy holidays,
> > Alexis.
> > 
> > 
> > ___
> > Qt-creator mailing list
> > Qt-creator@qt-project.org
> > https://lists.qt-project.org/listinfo/qt-creator
> > 
___
Qt-creator mailing list
Qt-creator@qt-project.org
https://lists.qt-project.org/listinfo/qt-creator


[Qt-creator] Quick test or scratch-pad mode in qtc?

2018-12-22 Thread Jeandet Alexis
Hello,

I was wondering if this would be totally stupid to have a mode in QTC
were we could code in a single source with no Build System setup?
I always go to websites like coliru, godbolt, wandbox,... to do some
tests(test concepts, see if I can template something,...) because this
is so convenient to just start writing code without any setup. But this
has many drawbacks like, no or almost no completion, no debug and needs
internet.

In QTC I would easily see a section in welcome page "scratch-pad" with
previous ones and a button to create a new one. I don't think we should
care about file location or any setup, source files could be stored in
QTC user data folder. Maybe we could just switch among available
compilers and set manually compile args like godbolt.

Am I the only one who miss this feature?
If no I will definitely open a BR.

Best regards and happy holidays,
Alexis.


___
Qt-creator mailing list
Qt-creator@qt-project.org
https://lists.qt-project.org/listinfo/qt-creator


Re: [Qt-creator] Subprojects handling

2014-01-08 Thread Jeandet Alexis
Le mercredi 08 janvier 2014 à 17:37 +0100, Yves Bailly a écrit :
 Le 08/01/2014 17:27, Mohamed Fawzi a écrit :
  Build  Run  General  Always build project before deploying it
 
  in the Options.
 
 But then the subproject I want to run is not build, I have to build
 it explicitly.
 
 Anyway it's the closest I can get to what I want it seems...
 
 Thanks all.
 
Hi,

From what I understand your problem is that creator works as expected,
it call make from the top directory and then make enter each sub-project
and update what it should. If you want to make it faster you can
parallelize it in the build option by adding -j N (N=number of process)
to the make arguments. 
Or also open your project as kai said in the same sessions you can open
all of them separately and also open your top project then just activate
the one you want.

regards,
Alexis.

___
Qt-creator mailing list
Qt-creator@qt-project.org
http://lists.qt-project.org/mailman/listinfo/qt-creator


[Qt-creator] BareMetal Target Plugin Configuration

2013-12-20 Thread Jeandet Alexis
Hello,

We discuss a little about your plugin on the Qt mailing list, first your
plugin a very good feature for Qtcreator. 
I tried to look how to use it, I started with this help:
http://doc-snapshot.qt-project.org/qtcreator-3.0/creator-developing-baremetal.html

But few things are unclear to me, is this version allowing me to debug
(step by step and breakpoint) my code? If yes I don't understand what
are all the fields for the configuration:

For the device I use the same as you (localhost same port ...)

But for for the kit I have my own qt kit for STM32F4 which works. I just
set the debugger to arm-none-eabi-gdb.

Then for the run settings I really don't understand. In my case use
st-util -p  on linux to start a gdb server, if I put this as custom
executable, on run it load the code on the target but on debug it says
that /usr/bin/st-util: not in executable format... 

Do you have any idea of what I did wrong?

best regards,
Alexis. 

___
Qt-creator mailing list
Qt-creator@qt-project.org
http://lists.qt-project.org/mailman/listinfo/qt-creator


Re: [Qt-creator] Pure C functions documentation with doxygen

2013-11-13 Thread Jeandet alexis

Hello,

I wrote a simple example with a header file containing some declarations 
and a C file calling them, it's not supposed to compile.
I add also a Doxyfile with the configuration I use, I can only have F1 
help with structures.
I also add in the C file a structure initialisation which the codeEditor 
doesn't like, If you have any solution.


Regards,
Alexis.
Le 06/11/2013 16:53, Nikolai Kosjar a écrit :

Hi!

On 11/02/2013 06:27 PM, jeandet alexis wrote:

I'm trying to generate some documentation with doxygen, for a pure C
project. I can get the qch file, Qtcreator seems to recognize it I can
get contextual help on structures but not on functions and typedefs. Is
there any trick? Is there a limitation, does it work with C functions?

Please provide a minimal project together with all the steps needed to
to reproduce this. Especially the doxygen command and the
file/line/column number at which you hit F1.

Nikolai

___
Qt-creator mailing list
Qt-creator@qt-project.org
http://lists.qt-project.org/mailman/listinfo/qt-creator



--
Alexis Jeandet
LPP
Ecole Polytechnique
Route de Saclay
91128 Palaiseau CEDEX
Tél: +33 1 69 33 58 59
Fax: +33 1 69 33 59 06



QtDoxygen_test.tar.gz
Description: application/gzip
___
Qt-creator mailing list
Qt-creator@qt-project.org
http://lists.qt-project.org/mailman/listinfo/qt-creator


[Qt-creator] Pure C functions documentation with doxygen

2013-11-02 Thread jeandet alexis
Hello,

I'm trying to generate some documentation with doxygen, for a pure C
project. I can get the qch file, Qtcreator seems to recognize it I can
get contextual help on structures but not on functions and typedefs. Is
there any trick? Is there a limitation, does it work with C functions?


regards,
Alexis.

___
Qt-creator mailing list
Qt-creator@qt-project.org
http://lists.qt-project.org/mailman/listinfo/qt-creator


Re: [Qt-creator] BareMetal Target Plugin

2013-08-14 Thread Jeandet alexis
Hello,

I'm interested in what you call a bare metal target, do you mean 
something like arm(CortexMx) or sparc target?
I started something similar, but it's just background work.

Le 14/08/2013 13:16, Daniel Teske a écrit :
 On Wednesday 14 Aug 2013 13:00:15 you wrote:
 Daniel wrote:
 Tim wrote:
 If i may deploy for a remote linux target which unfortunatly has no QT
 installed. I have a working qt installation and a working qmake
 (otherwise the project build with qmake would fail earlier). This is
 used to make a cross build without QT for the target. Currently all
 pieces in qtcreator are there but it can't be configured as the
 selection dialog is greyed out in the project configuration because
 the kit has no qt assigned. As qmake is used as a build tool with
 config -= qt there is no qt needed on the target device and so it
 should not be greyed out in this special case.
 But you still need to tell creator which qmake you want to use, which is
 done via the qt version. That does not in any way affect whether the
 resulting executable depends on qt.
 The problem is that just pointing to a qmake binary is not enough as
 Creator runs a couple of sanity checks to ensure the associated Qt build
 is usable. This is simply too much in this particular case.
 The ony requirements are, and I repeat myself here:
 - Various files in the mkspec directory, those are needed by qmake.
 - That the bin directory exists (which given that the qmake binary is in it is
 a rather easy requirement.
 - That the include directory exists, but that can be empty. That is the only
 one that is in addtion to what would work on the command line. We check that
 directory, since it is quite common for those who compile qt from source to
 not do a -prefix . build / not install.

 It is possible to trick Creator into believing that all is well by
 creating a dummy libQtCore.so matching the target architecture and copying
 parts of a real Qt's mkspec directory, but that's clearly a hack.
If here you mean a custom qmake version, I did it in a dirty way by 
compiling a Qt sdk with qmake and after I replaced all mkspec files and  
Qt libraries by my files. It works perfectly with QtCreator from 2.6 
to 2.8.
I can send you a Linux example if you want.
If somebody knows how to build qmake without the SDK I'm interested. And 
also if it could be possible to configure the qt path outside of qmake 
binary, something like a conf file or even qmake could get it's current 
path and
use it as qt path, it would make custom SDK distribution easier.
 That's wrong, there is no need to have a libQtCore.so.

 daniel
 ___
 Qt-creator mailing list
 Qt-creator@qt-project.org
 http://lists.qt-project.org/mailman/listinfo/qt-creator


-- 
Alexis Jeandet
LPP
Ecole Polytechnique
Route de Saclay
91128 Palaiseau CEDEX
Tél: +33 1 69 33 58 59
Fax: +33 1 69 33 59 06

___
Qt-creator mailing list
Qt-creator@qt-project.org
http://lists.qt-project.org/mailman/listinfo/qt-creator


[Qt-creator] .pro files parser Interface

2012-12-12 Thread Jeandet alexis
Hello,

I would like to write a Qt-creator plugin for flashing some 
microcontrollers(such as CortexM family or Leon3) because I also use 
Qt-creator as standalone IDE without Qt library. I've read this good 
introduction 
http://www.vcreatelogic.com/downloads/files/Writing-Qt-Creator-Plugins.pdf 
and I'm able to run a simple plugin.
But in my case I would like to access pro/pri files from my plugin, I've 
looked inside Qt-creator source and specially inside Qt4ProjectManager 
plugin, I've found some informations in Qt4ProFileNode class and 
Qt4Project::update*Model.
As I understand there is no simple way to query any projectFile variable 
from my plugin? Did I miss something?


Best regards,
Alexis.
___
Qt-creator mailing list
Qt-creator@qt-project.org
http://lists.qt-project.org/mailman/listinfo/qt-creator


Re: [Qt-creator] .pro files parser Interface

2012-12-12 Thread Jeandet alexis
Le 12/12/2012 13:23, Konstantin Tokarev a écrit :

 12.12.2012, 14:23, Jeandet alexis alexis.jean...@lpp.polytechnique.fr:
 Hello,

 I would like to write a Qt-creator plugin for flashing some
 microcontrollers(such as CortexM family or Leon3) because I also use
 Qt-creator as standalone IDE without Qt library. I've read this good
 introduction
 http://www.vcreatelogic.com/downloads/files/Writing-Qt-Creator-Plugins.pdf
 and I'm able to run a simple plugin.
 But in my case I would like to access pro/pri files from my plugin, I've
 looked inside Qt-creator source and specially inside Qt4ProjectManager
 plugin, I've found some informations in Qt4ProFileNode class and
 Qt4Project::update*Model.
 It would be great if your plugin was NOT bound to Qt4ProjectManager by design.
Yes this is also my feeling.
 This may require adding new APIs to ProjectExplorer, depending on data you'd
 like to access.

In my case I need to get some customs variables in pro/pri files. They 
look like:

CPU=stm32f4xxxG
BSP=STM32F4Discovery
DESTDIR=somepath

My plugin would use them to find the binary file to load (This could be 
done with /ProjectExplorer::RunConfigurations/  I think), but it need to 
know the CPU target and the the BSP to use the good tool and protocol to 
flash the target.

The problem is that they are in different files = I need to follow 
inclusion and sometime I need to evaluate qmake functions such as 
contains(variablename, value). I would prefer to use the same API as 
QtCreator,qmake,...  if there is one?


Thanks,
Alexis.
___
Qt-creator mailing list
Qt-creator@qt-project.org
http://lists.qt-project.org/mailman/listinfo/qt-creator