[Oangband 1.1.0u] Big screen modus

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • dcztmband
    Rookie
    • Jan 2011
    • 15

    [Oangband 1.1.0u] Big screen modus

    Hello,

    I'm just wondering: It seems, that there is no bis screen modus (option -- -b) in Oangband 1.1.0u available. There is no effect on my debian system, instead of it four sub windows are displayed.

    Is this right and how can I switch to big screen mode?

    Thanks in advance!
  • Nick
    Vanilla maintainer
    • Apr 2007
    • 9647

    #2
    What you're getting is the x11 front end - in that case you can just resize the main window. If you want to run in a terminal, use option -mgcu, and in that case you can resize the terminal to whatever size you want first. I use the SDL port (option -msdl); for that you need to have at least the SDL, SDL_ttf and SDL_image packages installed (and maybe one or two others - I don't exactly recall).

    Hope that helps.
    One for the Dark Lord on his dark throne
    In the Land of Mordor where the Shadows lie.

    Comment

    • dcztmband
      Rookie
      • Jan 2011
      • 15

      #3
      Originally posted by Nick
      What you're getting is the x11 front end - in that case you can just resize the main window. If you want to run in a terminal, use option -mgcu, and in that case you can resize the terminal to whatever size you want first. I use the SDL port (option -msdl); for that you need to have at least the SDL, SDL_ttf and SDL_image packages installed (and maybe one or two others - I don't exactly recall).

      Hope that helps.
      Hm, I complied Oangband without x11 and sdl:

      Code:
      ./configure --enable-curses --disable-x11
      and I run oangand using the command line (console), not switching to x11.

      Do you think, "oangband -mgcu -- -b -a" will work for big screen mode using the console (vga=795, 1280 x 1024)?

      All the best!

      Comment

      • Nick
        Vanilla maintainer
        • Apr 2007
        • 9647

        #4
        "oangband -mgcu -- -x" should work. It is just possible that, if your screen is too large, it may give you a "main window is too small" error; if that's the case, we should be able to hack main-gcu.c to make it work.

        Good luck!
        One for the Dark Lord on his dark throne
        In the Land of Mordor where the Shadows lie.

        Comment

        • dcztmband
          Rookie
          • Jan 2011
          • 15

          #5
          Originally posted by Nick
          "oangband -mgcu -- -x" should work.
          This works like a charm, thank you very much!

          Originally posted by Nick
          [...]we should be able to hack to make it work.
          By the way, I want to split the screen into three windows, not four as the default is.

          I managed this by hacking the main-gcu.c:
          Code:
          	/*** Now prepare the term(s) ***/
          
          	if (!split_window) num_term=1;
          
          	/* Create one or several terms */
          	for (i = 0; i < num_term; i++)
          	{
          		int rows, cols, y, x;
          
          		if (split_window)
          		{
          		        /* Hack - the main window is huge */
          		        /* Sub windows require a width of at least 25 and a height
          			 * if at least 6.  Furth excess height is split between the
          			 * main window and the others.
          			 */
          		        if (COLS > MIN_COLS_SPLIT) cols = 80 + (COLS - MIN_COLS_SPLIT) / 2;
          			else cols = COLS;
          			if (LINES > MIN_ROWS_SPLIT) rows = 24 + (LINES - MIN_ROWS_SPLIT) / 2;
          			else rows = LINES;
          		}
          		else
          		{
          		        cols=COLS;
          			rows=LINES;
          		}
          
          		/* Decide on size and position */
          		switch (i)
          		{
          			/* Upper center */
          			case 0:
          				y = x = 0;
          				break;
          
          			/* Lower left */
          			case 1:				
          				y = rows + 1;
          				x = 0;
          				rows = LINES - (rows + 1);
          				break;
          
          			/* Lower right */
          			case 2:				
          				y = rows + 1;
          				x = cols + 1;
          				rows = LINES - (rows + 1);
          				cols = COLS - (cols + 1);				
          				break;
          
          			/* XXX */
          			default:
          				rows = cols = y = x = 0;
          				break;
          		}
          
          		/* Skip non-existant windows */
          		if (rows <= 0 || cols <= 0) continue;
          
          		/* Create a term */
          		term_data_init_gcu(&data[next_win], rows, cols, y, x, i);
          
          		/* Remember the term */
          		angband_term[next_win] = &data[next_win].t;
          
          		/* One more window */
          		next_win++;
          	}
          But how can I expand the upper center window to 160 x 48 and the two lower windows to 80 x 16 chars? The final result should look like this:

          Code:
           _______________
          |               |
          |   160 x 48    |
          |_______________| 
          |_______|_______|
           80 x 16 80 x 16
          Any idea?

          Slight problem number two: The [ESC] key takes a little bit long (~ 1 second) to respond, can this be changed?

          Thank you!
          Last edited by dcztmband; February 1, 2011, 20:00.

          Comment

          • Nick
            Vanilla maintainer
            • Apr 2007
            • 9647

            #6
            While you're hacking, I think just adding

            Originally posted by dcztmband
            [CODE]
            {
            cols=COLS;
            rows=LINES;
            }

            ROWS = 48;
            COLS = 80;

            /* Decide on size and position */
            switch (i)
            Code:
             _______________
            |               |
            |   160 x 48    |
            |_______________| 
            |_______|_______|
             80 x 16 80 x 16
            should do it.
            Slight problem number two: The [ESC] key takes a little bit long (~ 1 second) to respond, can this be changed?
            IIRC using the backquote (`) instead of ESC works for the gcu port; if that fails try ESC twice. Someone else may correct me here.
            One for the Dark Lord on his dark throne
            In the Land of Mordor where the Shadows lie.

            Comment

            • dcztmband
              Rookie
              • Jan 2011
              • 15

              #7
              Hi Nick,

              adding this

              Code:
              {
              		        cols=COLS;
              			rows=LINES;
              		}
              
              			rows = 48;
              			cols = 80;
              
              		/* Decide on size and position */
              		switch (i)
              		{
              			/* Upper center */
                                      case 0:
              				y = x = 0;
              				break;
              to main-gcu.c results in one upper window with a size of 80x48 and two lower windows with size 80x16.

              Adding this

              Code:
              {
              		        cols=COLS;
              			rows=LINES;
              		}
              
              			rows = 48;
              			cols = 80;
              
              		/* Decide on size and position */
              		switch (i)
              		{
              			/* Upper center */
              			case 0:
              			rows = 48;
              			cols = 160;
              				y = x = 0;
              				break;
              does the trick: One top 160x48 window, two 80x16 windows, but starting in big screen mode using "oangband -- -x" results in one window with 160x48 instead of 160x64 size.

              How can this be fixed?

              Yes, using the backquote (`) instead of ESC works fine!

              Thank you very much!

              Comment

              Working...
              😀
              😂
              🥰
              😘
              🤢
              😎
              😞
              😡
              👍
              👎