Still Sierra Menubar

Started by Swegi, Thu 16/12/2004 02:07:43

Previous topic - Next topic

Swegi

I started to make my own Sierra menubar becouse i havn't found anything like i want.
if i click on "File" a new GUI should pop up. the problem is that it's no squer format.
It looks like this:

-----------------------------------------------------------
-------              -----------------------------------------
        |             |
        |             |
         -----------

and it just wont fit in the grey GUI format.  any idea?

Goot

What do you mean it won't fit in the gray GUI format? You can change the colors in the GUI settings pane if that's what you want to do. If you want to have a GUI pop up when you click a button, put InterfaceOn(x); in the script for that button. (read the section of the manual about GUIs if you don't know how to do that.) You'll need to make the popup square a separate GUI.

Swegi

i made the upper bar as a popup GUI. if i go with the mouse in the 1-9 line it pops up, if i click on the "File"  the popup winow appears( the bar stays becouse i deleted the line with the GuiOff). fine. but  if my mouse on the window area then the bar disappears, and only the window stay.

im a rookie as u can see it, but i have already made my own quite and text window, so i know a little bit about GUIs.(but not enough... :-\)

Scorpiorus

Can you post the code you have in repeatedly_execute in the main global script?

Swegi



if (interface == 3) { //this is the bar
   

    if (button == 0) {   // turn on Options-GUI when they click on "File"
      SetMouseCursor(0);

      InterfaceOn(4); // this is the window
      }
   
}

my repeatedly_execute is empty. this script is from interface_click

Scorpiorus

Ah, so you mean your ICONBAR visible propery is Mouse YPos, not PopupModal. :)

In that case, yes, that's how such a GUI works - it disappears as you move the mouse cursor away.

Change ICONBAR's visible property to PopupModal and make it to pop up with the following code:

function repeatedly_execute() {

   if (mouse.y < 10) GUIOn(3); // GUIOn is equivelentÃ,  for InterfaceOn
}

It won't close then but you should close it manually. For example, when you choose a menu item or ESC is pressed:

function on_key_press(int keycode) {


   if (keycode == 27)
   {
      GUIOff(3);
      GUIOff(<square window>);
   }

}

SMF spam blocked by CleanTalk