I am trying to compile and run this GUI code
#include "Graph.h" // get access to our graphics library facilities
int main()
{
using namespace Graph_lib; // our graphics facilities are in Graph_lib
Point tl{ 100,100 }; // to become top left corner of window
Simple_window win{ tl,600,400,"Canvas" }; // make a simple window
Polygon poly; // make a shape (a polygon)
poly.add(Point{ 300,200 }); // add a point
poly.add(Point{ 350,100 }); // add another point
poly.add(Point{ 400,200 }); // add a third point
poly.set_color(Color::red); // adjust properties of poly
win.attach(poly); // connect poly to the window
win.wait_for_button(); // give control to the display engine
}
source of headers and code files: http://www.stroustrup.com/Programming/PPP2code/
I get the hash_map error
Error (active) E0035 #error directive: <hash_map> is deprecated and will be REMOVED. Please use <unordered_map>. You can define _SILENCE_STDEXT_HASH_DEPRECATION_WARNINGS to acknowledge that you have received this warning. ConsoleApplication1 C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\VC\Tools\MSVC\14.24.28314\include\hash_map 21
What causes an hash_map error and how can I fix it?