On 7/13/2011 11:20 PM, ext Aekold Helbrass wrote:
> Good day All!
>
> Explain me please how QtCreator is handling blocks inside #ifdef. I
> expected that current system configuration should be analyzed and
> ifdef false blocks should be greyed out. But from time to time I see
> different story. Take a look at qfontengine_ft.cpp from Qt source
> code, we can see that block [1] is greyed out, and it's right. But
> then [2] is greyed out too while I have freetype 2.4.4, and [3] is
> greyed out too while I am sure I have FT_LCD_FILTER_H defined. So my
> question is: is there something wrong with QtCreator or something is
> wrong in my system?
>
>
> [1]:
> # if 0
> ... a lot of source code here .....
> #endif
>
> [2]
> #if (FREETYPE_MAJOR*10000 + FREETYPE_MINOR*100 + FREETYPE_PATCH)> 20103
> if (FT_IS_SFNT(face)) {
> FT_ULong len = *length;
> result = FT_Load_Sfnt_Table(face, tag, 0, buffer,&len) == FT_Err_Ok;
> *length = len;
> }
> #endif
>
> [3]
> #if defined(FT_LCD_FILTER_H)
> lcdFilterType = (int)((quintptr) FT_LCD_FILTER_DEFAULT);
> #endif
> _______________________________________________
>
Hi,
how you see the defines (greyed out or not) depend on a few things. The
basic idea is that such information is session-based in Creator and
shared across projects (all defines are merged together). So you might
get some "conflicting" situations if you have, for example, more than
one project open using different Qt versions.
Cheers,
Leandro
--
Leandro T. C. Melo
Software Engineer
Nokia, Qt Development Frameworks
Nokia gate5 GmbH
Firmensitz: Invalidenstr. 117, 10115 Berlin, Germany
Registergericht: Amtsgericht Charlottenburg, Berlin: HRB 106443B
Umsatzsteueridentifikationsnummer: DE 812 845 193
Geschäftsführer: Dr. Michael Halbherr, Karim Tähtivuori
_______________________________________________
Qt-creator mailing list
[email protected]
http://lists.qt.nokia.com/mailman/listinfo/qt-creator