Extending Qt Creator Manual | Overview

Extending Qt Creator Manual 4.5.2

# Overview Class

(CPlusPlus::Overview)

The Overview class converts a FullySpecifiedType and/or any qualified name to its string representation. More...

Header: | #include <Overview>

- List of all members, including inherited members

## Public Types

enum | StarBindFlag { BindToIdentifier, BindToTypeName, BindToLeftSpecifier, BindToRightSpecifier }
flags | StarBindFlags

## Public Functions

| Overview()
QString | prettyName(const Name *name) const
QString | prettyName(const QList<const Name *> &fullyQualifiedName) const
QString | prettyType(const FullySpecifiedType &type, const Name *name = 0) const
QString | prettyType(const FullySpecifiedType &type, const QString &name) const
QString | operator()(const Name *name) const
QString | operator()(const QList<const Name *> &fullyQualifiedName) const
QString | operator()(const FullySpecifiedType &type, const Name *name = 0) const

## Detailed Description

The Overview class converts a FullySpecifiedType and/or any qualified name to its string representation.

The public data members (except the ones starting with marked) determine what exactly and how to print.

You can get the start and end position of a function argument in the resulting string. Set `markedArgument` to the desired argument. After processing, `markedArgumentBegin` and `markedArgumentEnd` will contain the positions.

## Member Type Documentation

### enum Overview::StarBindFlag
flags Overview::StarBindFlags

The StarBindFlag enum describes how the '*' and '&' in pointers/references should be bound in the string representation.

This also applies to rvalue references ('&&'), but not to pointers to functions or arrays, because it seems to be quite uncommon to use spaces in them. For example:

      void (*p)()
      void (*p)[]

See the examples below. These assume that exactly one flag is set. That is, it may look different with flag combinations.

Constant | Value | Description
--- | --- | ---
`CPlusPlus::Overview::BindToIdentifier` | `0x1` | e.g. "char *foo", but not "char * foo"
`CPlusPlus::Overview::BindToTypeName` | `0x2` | e.g. "char*", but not "char *"
`CPlusPlus::Overview::BindToLeftSpecifier` | `0x4` | e.g. "char * const* const", but not "char * const * const"
`CPlusPlus::Overview::BindToRightSpecifier` | `0x8` | e.g. "char *const", but not "char * const"

The StarBindFlags type is a typedef for QFlags<StarBindFlag>. It stores an OR combination of StarBindFlag values.

## Member Function Documentation

### Overview::Overview()

Default constructs an instance of Overview.

### QString Overview::prettyName(const Name *name) const

### QString Overview::prettyName(const QList<const Name *> &fullyQualifiedName) const

### QString Overview::prettyType(const FullySpecifiedType &type, const Name *name = 0) const

### QString Overview::prettyType(const FullySpecifiedType &type, const QString &name) const

### QString Overview::operator()(const Name *name) const

### QString Overview::operator()(const QList<const Name *> &fullyQualifiedName) const

### QString Overview::operator()(const FullySpecifiedType &type, const Name *name = 0) const