undoStudio
The IDE of the undoRT ecosystem
Loading...
Searching...
No Matches
undoApp::ST::STDocument Struct Reference

One open ST file, held whole so it can be put back. More...

#include <undoAppST.hpp>

Collaboration diagram for undoApp::ST::STDocument:
Collaboration graph

Public Attributes

std::string path
 Absolute path, where a later save goes.
 
POUType pouType = POUType::Program
 PROGRAM, FUNCTION_BLOCK or FUNCTION.
 
std::string pouName
 Name of the POU.
 
std::string functionReturnType
 Return type of a FUNCTION.
 
std::string pouVariablesText
 The POU's VAR sections.
 
std::string pouBodyText
 The POU's body.
 
std::vector< MethodData > methods
 Its methods, with their texts.
 
float splitterPos = 0.5f
 Where the two panes were divided.
 
std::string activeTab
 Which method tab was showing, empty for the POU.
 

Detailed Description

One open ST file, held whole so it can be put back.

Everything openFile() reads out of the file, and nothing that can be worked out again from it: the AST, the semantic analysis and the source map are all derived, and keeping them would mean a snapshot that is stale the moment a character is typed.

The editor contents are the point of it. A tab that is still open has to come back showing what was in it, and reading the file off disk would give back the version on disk rather than the one being edited, which is the unsaved half of every change made since it was opened.

Member Data Documentation

◆ activeTab

std::string undoApp::ST::STDocument::activeTab

Which method tab was showing, empty for the POU.

◆ functionReturnType

std::string undoApp::ST::STDocument::functionReturnType

Return type of a FUNCTION.

◆ methods

std::vector<MethodData> undoApp::ST::STDocument::methods

Its methods, with their texts.

◆ path

std::string undoApp::ST::STDocument::path

Absolute path, where a later save goes.

◆ pouBodyText

std::string undoApp::ST::STDocument::pouBodyText

The POU's body.

◆ pouName

std::string undoApp::ST::STDocument::pouName

Name of the POU.

◆ pouType

POUType undoApp::ST::STDocument::pouType = POUType::Program

PROGRAM, FUNCTION_BLOCK or FUNCTION.

◆ pouVariablesText

std::string undoApp::ST::STDocument::pouVariablesText

The POU's VAR sections.

◆ splitterPos

float undoApp::ST::STDocument::splitterPos = 0.5f

Where the two panes were divided.


The documentation for this struct was generated from the following file: