| QCefView 1.0.7 A QWidget-based WebView Component Integrated with CEF

Loading...
Searching...
No Matches
Public Member Functions | List of all members
QCefSetting

Represents the settings for individual browser. More...

`#include <QCefSetting.h>`

## Public Member Functions
| QCefSetting ()
| Constructs the QCefSetting instance.
| QCefSetting (const QCefSetting &other)
| Constructs the QCefSetting instance from existing one.
QCefSetting & | operator= (const QCefSetting &other)
| Assigns the existing QCefSetting instance to current.
| ~QCefSetting ()
| Destructs the instance.
void | setOffScreenRenderingEnabled (const bool value)
| Sets the switch to enable or disable off-screen rendering.
const bool | OffScreenRenderingEnabled () const
| Gets the switch to enable or disable off-screen rendering.
void | setWindowInitialSize (const QSize &size)
| Sets the initial size of the browser.
const QSize | windowInitialSize () const
| Gets the initial size of the browser.
void | setStandardFontFamily (const QString &value)
| Sets the standard font family.
const QString | standardFontFamily () const
| Gets the standard font family.
void | setFixedFontFamily (const QString &value)
| Sets the fixed font family.
const QString | fixedFontFamily () const
| Gets the fixed font family.
void | setSerifFontFamily (const QString &value)
| Sets the serif font family.
const QString | serifFontFamily () const
| Gets the serif font family.
void | setSansSerifFontFamily (const QString &value)
| Sets the sans serif font family.
const QString | sansSerifFontFamily () const
| Gets the sans serif font family.
void | setCursiveFontFamily (const QString &value)
| Sets the cursive font family.
const QString | cursiveFontFamily () const
| Gets the cursive font family.
void | setFantasyFontFamily (const QString &value)
| Sets the fantasy font family.
const QString | fantasyFontFamily () const
| Gets the fantasy font family.
void | setDefaultEncoding (const QString &value)
| Sets the default encoding.
const QString | defaultEncoding () const
| Gets the default encoding.
void | setAcceptLanguageList (const QString &value)
| Sets the acceptable language list.
const QString | acceptLanguageList () const
| Gets the acceptable language list.
void | setWindowlessFrameRate (const int value)
| Sets the frame rate in window less mode.
const QVariant | windowlessFrameRate () const
| Gets the frame rate in window less mode.
void | setHardwareAccelerationEnabled (const bool value)
| Sets the switch to enable or disable the use of hardware acceleration for rendering.
const bool | hardwareAccelerationEnabled () const
| Gets the switch to enable or disable the use of hardware acceleration for rendering.
void | setDefaultFontSize (const int value)
| Sets the default font size.
const QVariant | defaultFontSize () const
| Gets the default font size.
void | setDefaultFixedFontSize (const int value)
| Sets the default fixed font size.
const QVariant | defaultFixedFontSize () const
| Gets the default fixed font size.
void | setMinimumFontSize (const int value)
| Sets the minimum font size.
const QVariant | minimumFontSize () const
| Gets the minimum font size.
void | setMinimumLogicalFontSize (const int value)
| Sets the minimum logical font size.
const QVariant | minimumLogicalFontSize () const
| Gets the minimum logical font size.
void | setRemoteFonts (const bool value)
| Sets to enable or disable remote fonts.
const QVariant | remoteFonts () const
| Gets whether to enable or disable the remote fonts.
void | setJavascript (const bool value)
| Sets to enable or disable Javascript.
const QVariant | javascript () const
| Gets whether to enable or disable Javascript.
void | setJavascriptCloseWindows (const bool value)
| Sets to enable or disable the permission of closing window from Javascript.
const QVariant | javascriptCloseWindows () const
| Gets whether to enable or disable the permission of closing window from Javascript.
void | setJavascriptAccessClipboard (const bool value)
| Sets to enable or disable the permission of accessing clipboard from Javascript.
const QVariant | javascriptAccessClipboard () const
| Gets whether to enable or disable the permission of accessing clipboard from Javascript.
void | setJavascriptDomPaste (const bool value)
| Sets to enable or disable the permission of pasting DOM in Javascript.
const QVariant | javascriptDomPaste () const
| Gets whether to enable or disable the permission of pasting DOM in Javascript.
void | setPlugins (const bool value)
| Sets to enable or disable plugins.
const QVariant | plugins () const
| Gets whether to enable or disable plugins.
void | setImageLoading (const bool value)
| Sets to enable or disable the permission of loading images.
const QVariant | imageLoading () const
| Gets whether to enable or disable the permission of loading images.
void | setImageShrinkStandaloneToFit (const bool value)
| Sets to enable or disable the shrinking image standalone to fit.
const QVariant | imageShrinkStandaloneToFit () const
| Gets whether to enable or disable the shrinking image standalone to fit.
void | setTextAreaResize (const bool value)
| Sets to enable or disable the resizing of text area.
const QVariant | textAreaResize () const
| Gets whether to enable or disable the resizing of text area.
void | setTabToLinks (const bool value)
| Sets to enable or disable tab to links.
const QVariant | tabToLinks () const
| Gets whether to enable or disable tab to links.
void | setLocalStorage (const bool value)
| Sets to enable or disable local storage.
const QVariant | localStorage () const
| Gets whether to enable or disable local storage.
void | setDatabases (const bool value)
| Sets to enable or disable database.
const QVariant | databases () const
| Gets whether to enable or disable database.
void | setWebGL (const bool value)
| Sets to enable or disable webGL.
const QVariant | webGL () const
| Gets whether to enable or disable webGL.
void | setBackgroundColor (const QColor &value)
| Sets the background color.
const QVariant | backgroundColor () const
| Gets the background color.

## Detailed Description

Represents the settings for individual browser.

## Constructor & Destructor Documentation

## ◆ QCefSetting() [1/2]

QCefSetting::QCefSetting | ( |  | ) |

Constructs the QCefSetting instance.

## ◆ QCefSetting() [2/2]

QCefSetting::QCefSetting | ( | const QCefSetting & | other | ) |

Constructs the QCefSetting instance from existing one.

Parameters

  other | The existing QCefSetting instance

## ◆ ~QCefSetting()

QCefSetting::~QCefSetting | ( |  | ) |

Destructs the instance.

## Member Function Documentation

## ◆ operator=()

QCefSetting & QCefSetting::operator= | ( | const QCefSetting & | other | ) |

Assigns the existing QCefSetting instance to current.

Parameters

  other |

## ◆ setOffScreenRenderingEnabled()

void QCefSetting::setOffScreenRenderingEnabled | ( | const bool | value | ) |

Sets the switch to enable or disable off-screen rendering.

Parameters

  value | True to enable; false to disable

This value is only used when QCefConfig::windowlessRenderingEnabled() is set to true.

## ◆ OffScreenRenderingEnabled()

const bool QCefSetting::OffScreenRenderingEnabled | ( |  | ) | const

Gets the switch to enable or disable off-screen rendering.

Returns
  True enabled; otherwise false

## ◆ setWindowInitialSize()

void QCefSetting::setWindowInitialSize | ( | const QSize & | size | ) |

Sets the initial size of the browser.

Parameters

  size | The initial size

## ◆ windowInitialSize()

const QSize QCefSetting::windowInitialSize | ( |  | ) | const

Gets the initial size of the browser.

Returns

## ◆ setStandardFontFamily()

void QCefSetting::setStandardFontFamily | ( | const QString & | value | ) |

Sets the standard font family.

Parameters

  value | The font family

## ◆ standardFontFamily()

const QString QCefSetting::standardFontFamily | ( |  | ) | const

Gets the standard font family.

Returns
  The font family

## ◆ setFixedFontFamily()

void QCefSetting::setFixedFontFamily | ( | const QString & | value | ) |

Sets the fixed font family.

Parameters

  value | The font family

## ◆ fixedFontFamily()

const QString QCefSetting::fixedFontFamily | ( |  | ) | const

Gets the fixed font family.

Returns
  The font family

## ◆ setSerifFontFamily()

void QCefSetting::setSerifFontFamily | ( | const QString & | value | ) |

Sets the serif font family.

Parameters

  value | The font family

## ◆ serifFontFamily()

const QString QCefSetting::serifFontFamily | ( |  | ) | const

Gets the serif font family.

Returns
  The font family

## ◆ setSansSerifFontFamily()

void QCefSetting::setSansSerifFontFamily | ( | const QString & | value | ) |

Sets the sans serif font family.

Parameters

  value | The font family

## ◆ sansSerifFontFamily()

const QString QCefSetting::sansSerifFontFamily | ( |  | ) | const

Gets the sans serif font family.

Returns
  The font family

## ◆ setCursiveFontFamily()

void QCefSetting::setCursiveFontFamily | ( | const QString & | value | ) |

Sets the cursive font family.

Parameters

  value | The font family

## ◆ cursiveFontFamily()

const QString QCefSetting::cursiveFontFamily | ( |  | ) | const

Gets the cursive font family.

Returns
  The font family

## ◆ setFantasyFontFamily()

void QCefSetting::setFantasyFontFamily | ( | const QString & | value | ) |

Sets the fantasy font family.

Parameters

  value | The font family

## ◆ fantasyFontFamily()

const QString QCefSetting::fantasyFontFamily | ( |  | ) | const

Gets the fantasy font family.

Returns
  The font family

## ◆ setDefaultEncoding()

void QCefSetting::setDefaultEncoding | ( | const QString & | value | ) |

Sets the default encoding.

Parameters

  value | The encoding name

## ◆ defaultEncoding()

const QString QCefSetting::defaultEncoding | ( |  | ) | const

Gets the default encoding.

Returns
  The encoding name

## ◆ setAcceptLanguageList()

void QCefSetting::setAcceptLanguageList | ( | const QString & | value | ) |

Sets the acceptable language list.

Parameters

  value | The acceptable languate list

Deprecated
  Deprecated since CEF 118.0.0

## ◆ acceptLanguageList()

const QString QCefSetting::acceptLanguageList | ( |  | ) | const

Gets the acceptable language list.

Returns
  The acceptable languate list

Deprecated
  Deprecated since CEF 118.0.0

## ◆ setWindowlessFrameRate()

void QCefSetting::setWindowlessFrameRate | ( | const int | value | ) |

Sets the frame rate in window less mode.

Parameters

  value | The frame rate

## ◆ windowlessFrameRate()

const QVariant QCefSetting::windowlessFrameRate | ( |  | ) | const

Gets the frame rate in window less mode.

Returns
  The frame rate

## ◆ setHardwareAccelerationEnabled()

void QCefSetting::setHardwareAccelerationEnabled | ( | const bool | value | ) |

Sets the switch to enable or disable the use of hardware acceleration for rendering.

Parameters

  value | The switch value

Since
  Introduced since CEF 125.0.0

## ◆ hardwareAccelerationEnabled()

const bool QCefSetting::hardwareAccelerationEnabled | ( |  | ) | const

Gets the switch to enable or disable the use of hardware acceleration for rendering.

Returns
  The switch value

Since
  Introduced since CEF 125.0.0

## ◆ setDefaultFontSize()

void QCefSetting::setDefaultFontSize | ( | const int | value | ) |

Sets the default font size.

Parameters

  value | The font size

## ◆ defaultFontSize()

const QVariant QCefSetting::defaultFontSize | ( |  | ) | const

Gets the default font size.

Returns
  The font size

## ◆ setDefaultFixedFontSize()

void QCefSetting::setDefaultFixedFontSize | ( | const int | value | ) |

Sets the default fixed font size.

Parameters

  value | The font size

## ◆ defaultFixedFontSize()

const QVariant QCefSetting::defaultFixedFontSize | ( |  | ) | const

Gets the default fixed font size.

Returns
  The font size

## ◆ setMinimumFontSize()

void QCefSetting::setMinimumFontSize | ( | const int | value | ) |

Sets the minimum font size.

Parameters

  value | The font size

## ◆ minimumFontSize()

const QVariant QCefSetting::minimumFontSize | ( |  | ) | const

Gets the minimum font size.

Returns
  The font size

## ◆ setMinimumLogicalFontSize()

void QCefSetting::setMinimumLogicalFontSize | ( | const int | value | ) |

Sets the minimum logical font size.

Parameters

  value | The font size

## ◆ minimumLogicalFontSize()

const QVariant QCefSetting::minimumLogicalFontSize | ( |  | ) | const

Gets the minimum logical font size.

Returns
  The font size

## ◆ setRemoteFonts()

void QCefSetting::setRemoteFonts | ( | const bool | value | ) |

Sets to enable or disable remote fonts.

Parameters

  value | True to enable; false to disable

## ◆ remoteFonts()

const QVariant QCefSetting::remoteFonts | ( |  | ) | const

Gets whether to enable or disable the remote fonts.

Returns
  True to enable; false to disable

## ◆ setJavascript()

void QCefSetting::setJavascript | ( | const bool | value | ) |

Sets to enable or disable Javascript.

Parameters

  value | True to enable; false to disable

## ◆ javascript()

const QVariant QCefSetting::javascript | ( |  | ) | const

Gets whether to enable or disable Javascript.

Returns
  True to enable; false to disable

## ◆ setJavascriptCloseWindows()

void QCefSetting::setJavascriptCloseWindows | ( | const bool | value | ) |

Sets to enable or disable the permission of closing window from Javascript.

Parameters

  value | True to enable; false to disable

## ◆ javascriptCloseWindows()

const QVariant QCefSetting::javascriptCloseWindows | ( |  | ) | const

Gets whether to enable or disable the permission of closing window from Javascript.

Returns
  True to enable; false to disable

## ◆ setJavascriptAccessClipboard()

void QCefSetting::setJavascriptAccessClipboard | ( | const bool | value | ) |

Sets to enable or disable the permission of accessing clipboard from Javascript.

Parameters

  value | True to enable; false to disable

## ◆ javascriptAccessClipboard()

const QVariant QCefSetting::javascriptAccessClipboard | ( |  | ) | const

Gets whether to enable or disable the permission of accessing clipboard from Javascript.

Returns
  True to enable; false to disable

## ◆ setJavascriptDomPaste()

void QCefSetting::setJavascriptDomPaste | ( | const bool | value | ) |

Sets to enable or disable the permission of pasting DOM in Javascript.

Parameters

  value | True to enable; false to disable

## ◆ javascriptDomPaste()

const QVariant QCefSetting::javascriptDomPaste | ( |  | ) | const

Gets whether to enable or disable the permission of pasting DOM in Javascript.

Returns
  True to enable; false to disable

## ◆ setPlugins()

void QCefSetting::setPlugins | ( | const bool | value | ) |

Sets to enable or disable plugins.

Parameters

  value | True to enable; false to disable

Deprecated
  Deprecated since CEF 100.0.0

## ◆ plugins()

const QVariant QCefSetting::plugins | ( |  | ) | const

Gets whether to enable or disable plugins.

Returns
  True to enable; false to disable

Deprecated
  Deprecated since CEF 100.0.0

## ◆ setImageLoading()

void QCefSetting::setImageLoading | ( | const bool | value | ) |

Sets to enable or disable the permission of loading images.

Parameters

  value | True to enable; false to disable

## ◆ imageLoading()

const QVariant QCefSetting::imageLoading | ( |  | ) | const

Gets whether to enable or disable the permission of loading images.

Returns
  True to enable; false to disable

## ◆ setImageShrinkStandaloneToFit()

void QCefSetting::setImageShrinkStandaloneToFit | ( | const bool | value | ) |

Sets to enable or disable the shrinking image standalone to fit.

Parameters

  value | True to enable; false to disable

## ◆ imageShrinkStandaloneToFit()

const QVariant QCefSetting::imageShrinkStandaloneToFit | ( |  | ) | const

Gets whether to enable or disable the shrinking image standalone to fit.

Returns
  True to enable; false to disable

## ◆ setTextAreaResize()

void QCefSetting::setTextAreaResize | ( | const bool | value | ) |

Sets to enable or disable the resizing of text area.

Parameters

  value | True to enable; false to disable

## ◆ textAreaResize()

const QVariant QCefSetting::textAreaResize | ( |  | ) | const

Gets whether to enable or disable the resizing of text area.

Returns
  True to enable; false to disable

## ◆ setTabToLinks()

void QCefSetting::setTabToLinks | ( | const bool | value | ) |

Sets to enable or disable tab to links.

Parameters

  value | True to enable; false to disable

## ◆ tabToLinks()

const QVariant QCefSetting::tabToLinks | ( |  | ) | const

Gets whether to enable or disable tab to links.

Returns
  True to enable; false to disable

## ◆ setLocalStorage()

void QCefSetting::setLocalStorage | ( | const bool | value | ) |

Sets to enable or disable local storage.

Parameters

  value | True to enable; false to disable

## ◆ localStorage()

const QVariant QCefSetting::localStorage | ( |  | ) | const

Gets whether to enable or disable local storage.

Returns
  True to enable; false to disable

## ◆ setDatabases()

void QCefSetting::setDatabases | ( | const bool | value | ) |

Sets to enable or disable database.

Parameters

  value | True to enable; false to disable

## ◆ databases()

const QVariant QCefSetting::databases | ( |  | ) | const

Gets whether to enable or disable database.

Returns
  True to enable; false to disable

## ◆ setWebGL()

void QCefSetting::setWebGL | ( | const bool | value | ) |

Sets to enable or disable webGL.

Parameters

  value | True to enable; false to disable

## ◆ webGL()

const QVariant QCefSetting::webGL | ( |  | ) | const

Gets whether to enable or disable webGL.

Returns
  True to enable; false to disable

## ◆ setBackgroundColor()

void QCefSetting::setBackgroundColor | ( | const QColor & | value | ) |

Sets the background color.

Parameters

  value | The color

This only works if the web page has no background color set. The alpha component value will be adjusted to 0 or 255, it means if you pass a value with alpha value in the range of [1, 255], it will be accepted as 255. The default value is inherited from QCefConfig::backgroundColor()

## ◆ backgroundColor()

const QVariant QCefSetting::backgroundColor | ( |  | ) | const

Gets the background color.

Returns
  The color