Skip to content

CopperSpice Journal

CopperSpice Journal

Author: Barbara Geller

Source Code  (Gui Example 27)

Posted on June 29, 2022July 4, 2022 By Barbara Geller

In this example a tool bar is added to a user application. A tool bar typically contains the most commonly used menu items. The same actions and icons used for the menu will be used on the tool bar.

Uncategorized

Source Code  (Gui Example 26)

Posted on June 20, 2022July 3, 2022 By Barbara Geller

This example will show how to create a user application which contains a top level menu. Adding a menu bar with icons and shortcuts is the next step in creating a graphical application.

Uncategorized

Source Code  (Gui Example 25)

Posted on June 7, 2022June 8, 2022 By Barbara Geller

This example uses a QTreeView with the QFileSystemModel to display the structure of a file system.

Uncategorized

Source Code  (Gui Example 24)

Posted on May 30, 2022May 31, 2022 By Barbara Geller

A QTreeView arranges a group of data elements based on a parent-child relationship. Top level items can be empty or have child items. Items which do have children can be expanded or collapsed and the child elements will be displayed or hidden. The QStandardItemModel will be used to store the data.

Uncategorized

Source Code  (Gui Example 23)

Posted on May 23, 2022May 30, 2022 By Barbara Geller

The QTableView class is used to display multiple rows and columns of data. This view makes sense when the data resides in a multi-dimensional container or a database. Since our data is stored in an SQL table we will use the QSqlTableModel to populate the view.

Uncategorized

Source Code  (Gui Example 22)

Posted on May 6, 2022May 30, 2022 By Barbara Geller

This example shows how to use a QListView to display a list of strings in a view where each row contains one item. Users can add, edit, and remove entries and the list will remain sorted. A string model is used to store the data and a proxy model is used to automatically sort the data.

Uncategorized

Source Code  (Gui Example 21)

Posted on April 22, 2022April 27, 2022 By Barbara Geller

This example shows several different frame styles which can be added to a variety of GUI widgets. A frame can also be used to group a collection of related widgets. The purpose of using a frame is to change the visual appearance of the boarder around a single widget or a group of widgets.

Uncategorized

Source Code  (Gui Example 20)

Posted on March 31, 2022May 29, 2022 By Barbara Geller

A common requirement for applications is to save user settings when an application is closed and then restore them the next time the application is opened. This example shows how to save information about the application and text the user has entered.

Uncategorized

Source Code  (Gui Example 19)

Posted on March 28, 2022April 11, 2022 By Barbara Geller

This example will show how to use check boxes and radio buttons on the pages of a Tab Widget. The layout of a tab page may contain any number of controls and the number of pages is unlimited.

Uncategorized

Source Code  (Gui Example 18)

Posted on March 15, 2022April 11, 2022 By Barbara Geller

The code in this example compares the three built in GUI widgets which are used to edit text. Each of these controls offers slightly different functionality and features.

Uncategorized

Source Code  (Gui Example 17)

Posted on March 4, 2022April 11, 2022 By Barbara Geller

The QLineEdit control appears in a user interface when a word or single line of text should be entered by the user. It is common for the entry to be a word which starts with the same letter. This example will show how to implement a completer which offers a list of predefined words for auto completion.

Uncategorized

Source Code  (Gui Example 16)

Posted on February 24, 2022April 11, 2022 By Barbara Geller

The QCalendarWidget displays a monthly calendar which allows a user a convenient way to select a date. In this example we will show how to change the colors for various days of the week.

Uncategorized

Source Code  (Gui Example 15)

Posted on February 24, 2022April 11, 2022 By Barbara Geller

The QCalendarWidget displays a monthly calendar which allows a user a convenient way to select a date. In this example we will show how to modify which day of the week the calendar should start on and various other appearance settings.

Uncategorized

Source Code  (Gui Example 14)

Posted on February 24, 2022April 11, 2022 By Barbara Geller

The QCalendarWidget displays a monthly calendar which allows a user a convenient way to select a date. This code shows how to set the minimum and maximum date range for a calendar.

Uncategorized

Finding the Documentation and Videos

Posted on February 15, 2022May 29, 2022 By Barbara Geller

The CopperSpice documentation is extensive, so let’s break it down into some smaller components. We have multiple tutorials and videos about programming and using C++. This article will explain where to find all of these.

Uncategorized

Posts navigation

1 2 3 Next
  • CopperSpice Journal Homepage
    • Table of Contents
    • Example Source Code
    • Discussion Forum
  • CopperSpice Homepage
  • Github Repository
  • Videos About C++

Copyright © 2021-2022 CopperSpice