KDevelop API Documentation

PascalSupportPart Class Reference

This is Pascal language support plugin. More...

#include <pascalsupport_part.h>

Inheritance diagram for PascalSupportPart:

Inheritance graph
[legend]
Collaboration diagram for PascalSupportPart:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 PascalSupportPart (QObject *parent, const char *name, const QStringList &)
 ~PascalSupportPart ()
virtual Features features ()
 Returns the feature set of the language.
virtual KMimeType::List mimeTypes ()
 Returns a typical mimetype list for the support language should be configurable in the languagesupport dialog.
virtual QString formatTag (const Tag &tag)
 Formats a Tag as used by the class store to the human-readable convention.
virtual QString formatModelItem (const CodeModelItem *item, bool shortDescription=false)
 Formats a CodeModelItem as used by the CodeModel to the human-readable convention.

Private Slots

void projectOpened ()
void projectClosed ()
void savedFile (const KURL &fileName)
void configWidget (KDialogBase *dlg)
void projectConfigWidget (KDialogBase *dlg)
void contextMenu (QPopupMenu *popup, const Context *context)
void addedFilesToProject (const QStringList &fileList)
void removedFilesFromProject (const QStringList &fileList)
void slotProjectCompiled ()
void initialParse ()

Private Member Functions

void maybeParse (const QString &fileName)
void parse (const QString &fileName)

Private Attributes

QGuardedPtr< PascalSupportWidget > m_widget
bool m_projectClosed
QStringList m_projectFileList
PascalSupportPartDatad

Detailed Description

This is Pascal language support plugin.

Pascal support provides good fpc and dcc compiler support by compiler plugins. Nearly all command line switches for those compilers can be configured in Project Options. Language parser exists but it isn't perfect yet.

In order to generate the parser by hand, antlr v2.7.2 is required. There are parser compilation errors with some gcc versions. To avoid them, replace file antlr/CppCodeGenerator.java in the antlr source code tree with the one from ftp://fara.cs.uni-potsdam.de/incoming/CppCodeGenerar.java.gz.

Author(s):
Alexander Dymo

Maintainer(s):
Alexander Dymo

Feature(s):
Pascal language support

Consult Programming Languages Support Status for a up to date features/status of this programming language support part.

Bug:
Language parser can sometimes treat correct lines as errors. Please send sample code to maintainer if you have this problem.

F.A.Q.:
Why KDevelop does not provide GNU pascal compiler plugin? If you need GNU pascal compiler plugin, please write about it to maintainer and prepare to help testing it.

Compiler plugin lacks option X. Write about it to maintaner or send a patch. Adding compiler options is easy task. Just look at languages/pascal/compiler directory.

Definition at line 22 of file pascalsupport_part.h.


Constructor & Destructor Documentation

PascalSupportPart::PascalSupportPart QObject parent,
const char *  name,
const QStringList
 

PascalSupportPart::~PascalSupportPart  ) 
 

Definition at line 76 of file pascalsupport_part.cpp.

References d, KDevPlugin::mainWindow(), PascalSupportPartData::problemReporter, and KDevMainWindow::removeView().


Member Function Documentation

void PascalSupportPart::addedFilesToProject const QStringList fileList  )  [private, slot]
 

Definition at line 135 of file pascalsupport_part.cpp.

References KDevLanguageSupport::addedSourceInfo(), maybeParse(), KDevPlugin::project(), and KDevProject::projectDirectory().

Referenced by projectOpened().

void PascalSupportPart::configWidget KDialogBase dlg  )  [private, slot]
 

Definition at line 110 of file pascalsupport_part.cpp.

void PascalSupportPart::contextMenu QPopupMenu popup,
const Context context
[private, slot]
 

Definition at line 122 of file pascalsupport_part.cpp.

PascalSupportPart::Features PascalSupportPart::features  )  [virtual]
 

Returns the feature set of the language.

This is e.g. used by the class view to decide which organizer items to display and which not.

Reimplemented from KDevLanguageSupport.

Definition at line 84 of file pascalsupport_part.cpp.

References KDevLanguageSupport::Features.

QString PascalSupportPart::formatModelItem const CodeModelItem item,
bool  shortDescription = false
[virtual]
 

Formats a CodeModelItem as used by the CodeModel to the human-readable convention.

Reimplemented from KDevLanguageSupport.

Definition at line 281 of file pascalsupport_part.cpp.

References FunctionModel::argumentList(), ArgumentList, ArgumentModel::defaultValue(), KDevLanguageSupport::formatModelItem(), CodeModelItem::isArgument(), CodeModelItem::isFunction(), CodeModelItem::isFunctionDefinition(), CodeModelItem::isVariable(), FunctionModel::isVirtual(), CodeModelItem::name(), FunctionModel::resultType(), ArgumentModel::type(), and VariableModel::type().

QString PascalSupportPart::formatTag const Tag &  tag  )  [virtual]
 

Formats a Tag as used by the class store to the human-readable convention.

Reimplemented from KDevLanguageSupport.

Definition at line 252 of file pascalsupport_part.cpp.

void PascalSupportPart::initialParse  )  [private, slot]
 

Definition at line 162 of file pascalsupport_part.cpp.

References KDevProject::allFiles(), d, kdDebug(), KDevPlugin::mainWindow(), maybeParse(), PascalSupportPartData::problemReporter, KDevPlugin::project(), KDevProject::projectDirectory(), KDevMainWindow::statusBar(), and KDevLanguageSupport::updatedSourceInfo().

Referenced by projectOpened().

void PascalSupportPart::maybeParse const QString fileName  )  [private]
 

Definition at line 186 of file pascalsupport_part.cpp.

References KMimeType::findByURL(), kdDebug(), KDevPlugin::mainWindow(), parse(), KMimeType::Ptr, and KDevMainWindow::statusBar().

Referenced by addedFilesToProject(), initialParse(), and savedFile().

KMimeType::List PascalSupportPart::mimeTypes  )  [virtual]
 

Returns a typical mimetype list for the support language should be configurable in the languagesupport dialog.

Reimplemented from KDevLanguageSupport.

Definition at line 243 of file pascalsupport_part.cpp.

References KMimeType::List, KMimeType::mimeType(), and KMimeType::Ptr.

void PascalSupportPart::parse const QString fileName  )  [private]
 

Definition at line 198 of file pascalsupport_part.cpp.

References PascalParser::compilationUnit(), d, data, PascalParser::getAST(), PascalParser::initializeASTFactory(), kdDebug(), PascalParser::numberOfErrors(), PascalLexer::numberOfErrors(), JAVADebugger::parser, PascalSupportPartData::problemReporter, RefPascalAST, ProblemReporter::reportError(), PascalParser::resetErrors(), PascalLexer::resetErrors(), PascalParser::setProblemReporter(), and PascalLexer::setProblemReporter().

Referenced by maybeParse().

void PascalSupportPart::projectClosed  )  [private, slot]
 

Definition at line 105 of file pascalsupport_part.cpp.

References m_projectClosed.

void PascalSupportPart::projectConfigWidget KDialogBase dlg  )  [private, slot]
 

Definition at line 116 of file pascalsupport_part.cpp.

void PascalSupportPart::projectOpened  )  [private, slot]
 

Definition at line 89 of file pascalsupport_part.cpp.

References addedFilesToProject(), KDevProject::allFiles(), initialParse(), m_projectClosed, m_projectFileList, KDevPlugin::project(), removedFilesFromProject(), and slotProjectCompiled().

void PascalSupportPart::removedFilesFromProject const QStringList fileList  )  [private, slot]
 

Definition at line 146 of file pascalsupport_part.cpp.

References KDevLanguageSupport::aboutToRemoveSourceInfo(), KDevPlugin::codeModel(), KDevPlugin::project(), KDevProject::projectDirectory(), and CodeModel::removeFile().

Referenced by projectOpened().

void PascalSupportPart::savedFile const KURL fileName  )  [private, slot]
 

Definition at line 129 of file pascalsupport_part.cpp.

References maybeParse(), KURL::path(), and KDevLanguageSupport::updatedSourceInfo().

void PascalSupportPart::slotProjectCompiled  )  [private, slot]
 

Definition at line 157 of file pascalsupport_part.cpp.

Referenced by projectOpened().


Member Data Documentation

PascalSupportPartData* PascalSupportPart::d [private]
 

Reimplemented from KDevPlugin.

Definition at line 58 of file pascalsupport_part.h.

Referenced by initialParse(), parse(), and ~PascalSupportPart().

bool PascalSupportPart::m_projectClosed [private]
 

Definition at line 55 of file pascalsupport_part.h.

Referenced by projectClosed(), and projectOpened().

QStringList PascalSupportPart::m_projectFileList [private]
 

Definition at line 56 of file pascalsupport_part.h.

Referenced by projectOpened().

QGuardedPtr<PascalSupportWidget> PascalSupportPart::m_widget [private]
 

Definition at line 53 of file pascalsupport_part.h.


The documentation for this class was generated from the following files:
KDE Logo
This file is part of the documentation for KDevelop Version 3.1.2.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Tue Feb 22 09:45:23 2005 by doxygen 1.3.9.1 written by Dimitri van Heesch, © 1997-2003