On Apr 24, 2010, at 11:51 PM, ext Danny Price wrote:
>
> On 24 Apr 2010, at 22:22, Robert Hairgrove wrote:
>>>
>>
>> This is also an issue in non-Qt apps. Just change this line:
>> std::cout << "test";
>> to this:
>> std::cout << "test" << std::endl;
>>
>> On some platforms (*nix, I
Note that endl includes an implicit flush, so this isn't really news.
Buffered I/O is buffered I/O and you should never write code that
depends on buffered I/O being output before an explicit flush.
By the way, IIRC, fflush(stdout) should work for stdio.h I/O.
/s/ Adam
On Sat, Apr 24, 2010 at 4
On 24 Apr 2010, at 22:22, Robert Hairgrove wrote:
>>
>
> This is also an issue in non-Qt apps. Just change this line:
> std::cout << "test";
> to this:
> std::cout << "test" << std::endl;
>
> On some platforms (*nix, I think) you need to do this in order to keep
> the next output fro
OSX 10.6.3 Leopard, Qt 4.6.2, Creator build 1.3.83 (rev 026237b008).
pro:
SOURCES += main.cpp
CONFIG += console
Build log:
Running build steps for project ArrayTest...
Starting: /usr/bin/make clean -w
make: Entering directory `/Users/ks/Projects/ArrayTest-build'
rm -f main.o
rm -f *~ core *.c
Danny Price wrote:
> Definitely an issue here. I created a C++ project and added CONFIG +=
> console to the pro file. The following does NOT print to the console
> until after main returns (as shown with a breakpoint)
>
>
> #include
> int main()
> {
> std::cout << "test";
> return 0;
> }
Thi
Strange, as was expected, works for me. Could you please attach the
console output of your compiler. And give the information about your
environment.
Thank you.
On 2010/04/24, at 21:25, Danny Price wrote:
> Definitely an issue here. I created a C++ project and added CONFIG
> += console to
Definitely an issue here. I created a C++ project and added CONFIG += console
to the pro file. The following does NOT print to the console until after main
returns (as shown with a breakpoint)
#include
int main()
{
std::cout << "test";
return 0;
}
However if I add cout.flush()
Berk Demirkır wrote:
A simple program output that prints a lot via printf don't show on
Application Output. But when i close this application output shows.
Strange issue...
Sounds like the output buffer is not being flushed.
Cheers,
Brad
___
Qt-cre
Hi,
I didn't checked "console" config option enabled in my project but printf
outputs are problematic i think.
A simple program output that prints a lot via printf don't show on
Application Output. But when i close this application output shows. Strange
issue...
On Wed, Apr 14, 2010 at 11:18, Br
nobodyhere wrote:
> thanks for the links - I will definitely read debug.html
>
> PS: The reason I considered it Qt Creator list, is that I was specifically
> asking about stdout not showing up in the Qt Creator GUI's "Application
> Output". However, qDebug() did show up in the Qt Creator "Applic
t;Application Output"
- Original Message -
From: "Sunil Thaha"
To: qt-creator@trolltech.com
Sent: Tuesday, April 13, 2010 11:22:14 PM GMT -06:00 US/Canada Central
Subject: Re: [Qt-creator] printf() with Qt Creator?
This should help you - http://sector.ynet.sk/qt4-tutorial/debugging.h
This should help you - http://sector.ynet.sk/qt4-tutorial/debugging.html,
http://doc.trolltech.com/4.6/debug.html
BTW: This mailinglist is specific to Qt-Creator issues. You might want to
post questions related to Qt in qt-interest mailinglist.
Regards,
Sunil
On Wed, Apr 14, 2010 at 7:00 AM, no
I googled for "stdout" rather than "printf", and I came across a special Qt
method, qDebug(), and it works:
#include
qDebug("qDebug, printf style, %i\n", 5);
qDebug() << "qDebug cout style, " << 5;
I'm not sure about this whole thing about using Qt's version of STL... But I
think for this new
I created a new Qt4 Gui Application, and did a printf(). The printf() works
(ie, goes to the Application Output) when I run via "Start Debugging F5".
However, it doesn't print when I run via "Run, Ctrl+R". :-(
___
Qt-creator mailing list
Qt-creator@t
14 matches
Mail list logo