Learn R Programming

qtbase (version 1.1.0)

qrTextFormattingDelegate: R-style Text Formatting Delegate

Description

Constructs an object of class RTextFormattingDelegate, which implements QItemDelegate for displaying text using the R formatting engine. This allows table and tree widgets (and any other widget that delegates to ItemDelegate) to correctly display NA values and to display numbers using the scipen and digits options.

Usage

qrTextFormattingDelegate(parent = NULL)

Arguments

parent
The parent object, or NULL for none.

Value

  • An RTextFormattingDelegate object

Examples

Run this code
data(mtcars)
model <- qdataFrameModel(mtcars)
view <- Qt$QTableView()
view$setModel(model)
delegate <- qrTextFormattingDelegate()
view$setItemDelegate(delegate)
view

Run the code above in your browser using DataLab