title: creating clickable "buttons" c++
body: <p>hey i am trying to basically just make a button in my little console application which can be pressed. here's a snippet of what i use to get the cursor location</p>
  
  <pre><code>if (GetKeyState(VK_LBUTTON) &lt; 0) {
  
  {
  POINT p;
  if (GetCursorPos(&amp;p))
  {
  cout&lt;&lt;"\nSCREEN\nx coord-&gt;";
  cout&lt;&lt;p.x;
  cout&lt;&lt;"\ny coord-&gt;";
  cout&lt;&lt;p.y;
  
  }
  SetConsoleTitle("paint");
  HWND hWnd;
  hWnd = FindWindow(NULL, "paint");
  
  
  if (ScreenToClient(hWnd, &amp;p));
  {
  cout&lt;&lt;"\n\nWINDOW\nx coord-&gt;";
  cout&lt;&lt;p.x;
  cout&lt;&lt;"\ny coord-&gt;";
  cout&lt;&lt;p.y;
  }
  int pwx;
  int pwy;
  
  pwx=p.x;
  pwy=p.y;
  </code></pre>
  
  <p>this just prints the mouse coords relative to the screen and to the window to the console. i got a function in which i can draw the ascii-symbol 219 to basically "paint" in the console wherever the mouse is and whenever the left mousebutton is held down.
  now:
  how can i detect a click within console characters?</p>
  
  <pre><code>    cout&lt;&lt;"press here to clear the screen-&gt;[x]";
  </code></pre>
  
  <p>the 2 square brackets and the 'x' should be pressable.
  i can only search for pixels with the above code, but not for rows and columns..
  is there a way to do this or am i completely off the track?</p>
  
  <p>i'm using code::blocks
  thanks for your help!</p>
  
  <p>[ i just started programming like a week ago so be nice :) ]</p>