ICProjectDescriptionManager mngr = CoreModel.getDefault().getProjectDescriptionManager();
IProject[] projects = ResourcesPlugin.getWorkspace().getRoot().getProjects();
for (int curProject = 0; curProject < projects.length; curProject++) {
ICProjectDescription projectDescription = mngr.getProjectDescription(projects[curProject], true);
if (projectDescription != null) { // if the description is null it probably is not a cdt project
ICConfigurationDescription configurationDescriptions[] = projectDescription.getConfigurations();
boolean projectDescriptionChanged = false;
for (int curConfigDescription = 0; curConfigDescription < configurationDescriptions.length; curConfigDescription++) {
ICFolderDescription folderDescription = configurationDescriptions[curConfigDescription].getRootFolderDescription();
ICLanguageSetting[] languageSettings = folderDescription.getLanguageSettings();