1: //test_displayopeningscreen.cpp 2: //A test driver for the Scobey::DisplayOpeningScreen() free function. 4: #include <iostream> 5: using namespace std; 7: #include "utilities.h" 8: using Scobey::DisplayOpeningScreen; 9: using Scobey::Pause; 11: int main() 12: { 13: Pause(0, "\nTesting the Scobey::DisplayOpeningScreen() free function ..." 14: "\n\nWe display three examples of an opening screen produced " 15: "by this function.\nThe first is the default display."); 17: DisplayOpeningScreen(); 19: DisplayOpeningScreen("Scobey:Porter:A00123456:csc34101", 20: "This is a demo program illustrating the DisplayOpeningScreen() " 21: "function."); 23: DisplayOpeningScreen("Scobey:Porter:A00123456:csc34101", 24: "This is a demo program with several lines of description " 25: "on the opening screen,\nwhich is much more than you should " 26: "normally have for a typical \"brief\" program\ndescription " 27: "or title, but it gives us a chance to see how the before-and-" 28: "after\nline-spacing parameters provide blank space preceding " 29: "and following the lines\nof displayed text. Note how they can " 30: "be adjusted to produce a display that is\nvertically-centered " 31: "if desired. If your displayed text does extend over more\nthan " 32: "one line, be sure that no word is split across two adjacent " 33: "output lines.", 34: 15, 9); 36: Pause(0, "No more tests to perform." 37: "\nProgram will now terminate."); 38: }