Learing on my own =>  C++.
Using codeblocks as my IDE. Arch linux
I use the following function to clear my terminal throughout my program. 
void        Clear_Screen(bool RESET)
{
  if (!cur_term)
        {
            int result = 0;
            setupterm(NULL,STDOUT_FILENO,&result);
            if (result <=0) 
                return;
        }
        putp(tigetstr( "clear"));
        if (RESET == true)
            putp(tigetstr( "rs1"));
}
no errors building.
whenever I run the program it works flawless!
When I use debug the "clear" does not perform as I would like but instead the output just scrolls.
This is because the "int result;" is returning a -1 when observed through the debugger - hence no clear.
I found that -1 is the return value for "An error occurred while locating the terminfo database."??
I used devilspie to find that the XTerm window opened when the program is ran - is called "CB_Console_Runner" and when in Debug it is called "sleep".
What is behind the no clear in debug??