-
Console buffer problem?
In the snippet of code below i have it output lines to form a box around the console window. But in the very last sqaure on row 26 column 80 when i place a sqaure it pushes
the text down to the next row. As in.
What i want:
▓------▓
|------|
|------|
|------|
|------|
▓------▓
What the console window looks like:
|------|
|------|
|------|
|------|
▓------▓
Newline
Im wondering what the problem is. And the ReadString Function is not the source of the problem. I have set the buffer size to X 80 Y 26 and window size to 800 350.
The objective would be to place a ascii character in that sqaure without it in a way "Pushing the screen down 1 row".
Code:
void LoadGwindow()
{
int LeftSide = 0;
int RightSide = 79;
int TopSide = 0;
int BottomSide = 25;
string HLine = "-";
string VLine = "|";
char Sqaure = char(178);
string Corner(&Sqaure, 1);
//Loading Frame//
//Top//
ReadString(HLine,0,78,LeftSide+1,TopSide,2);
//Bottom//
ReadString(HLine,0,78,LeftSide+1,BottomSide,2);
//Left//
ReadString(VLine,0,24,LeftSide,TopSide+1,1);
//Right//
ReadString(VLine,0,24,RightSide,TopSide+1,1);
//LeftTopCorner//
ReadString(Corner,0,1,LeftSide,TopSide,1);
//RightTopCorner
ReadString(Corner,0,1,RightSide,TopSide,1);
//LeftBottomCorner
ReadString(Corner,0,1,LeftSide,BottomSide,1);
//RightBottomCorner
ReadString(Corner,0,1,RightSide,BottomSide,1);
}