Hi,
Yes, it's possible to control the direction of menu, for example:
menu items left to right, icon is above text:
panel
{
direction = left_to_right
panel
{
direction = top_to_bottom
image { halign=center image=icon1.png }
text { halign=center text=os1 }
command="true"
}
panel
{
direction = top_to_bottom
image { halign=center image=icon2.png }
text { halign=center text=os2 }
command="true"
}
}
menu items top to bottom, text left of icon:
panel
{
direction = top_to_bottom
panel
{
direction = left_to_right
image { valign=center image=icon1.png }
text { valign=center text=os1 }
}
panel
{
direction = left_to_right
image { valign=center image=icon2.png }
text { valign=center text=os2 }
}
}
You can also let the system generate the above menu for you, this is
useful when there are a lot of items. But only one menu can be
generated. You need to split it into several parts, for example:
screen
{
panel
{
direction = left_to_right
id = __menu__
}
}
template_menuitem
{
pane
{
parameters = "class=image.class:title=text.text"
direction = top_to_bottom
image { halign=center }
text { halign=center }
}
}
class
{
image_os1 { image=os1.png }
image_os2 { image=os2.png }
}
Then in grub.cfg, you can use these command to add menu items:
menuentry "os1" --class image_os1 {
true
}
>
> OFF-TOPIC: My /boot directory is on a separate partition from my root
> directory. For some reason /etc/grub.d/00_header is generating 'set
> root=(hd0,7)', my root parition instead of 'set root=(hd0,1)' my /boot
> partition. I guess this won't be an issue if I end up completely
> overriding my grub.cfg but I was having issues with loading themes I
> had installed on my /boot partition until i moved them since grub was
> only mounting my root. I don't really understand what it's doing but
> my wild guess is this line is at fault 'prepare_grub_to_access_device `
> ${grub_probe} --target=device ${GRUB_FONT_PATH}`' can anyone shed any
> light on this?
I think this is a bug in the original grub, I'd take a look at it when
I have more time.
> Also, I read somewhere that Snow Leopard isn't supported by grub2 yet
> and I have to chain boot to Chameleon. Anyone know if this is also
> true about burg?
The xnu part is written by phcoder, so the function in burg should be
identical to grub.
--
Bean
Project: https://launchpad.net/burg
Document: https://help.ubuntu.com/community/Burg
Mailing list: burg-...@googlegroups.com
Hi,
Could you post your config file ? I have no problem start it in qemu.
Hi,
That's quite nice. I'd add that step in my document later.
> Unfortunatley I'm having trouble changing the gfxmode setting in my
> virtual machine. I can get the themed display but i can't change the
> screen resolution like I can on my actual machine. vbeinfo in the
> virtual machine outputs an empty list. Is this a limitation of the
> virtual machine?
If you're using qemu, then no need to worry about vbeinfo output, just
set whatever screen resolution you want, qemu can support any
resolution.
Hi,
That looks great, looking forward to see the end result.
Hi,
Oh sorry, I just check, qemu can't handle all resolution. Perhaps you
can try VirtualBox, vbeinfo command works, and it seems to support
1152x864 and 1600x1200.
--
Bean
Project: https://launchpad.net/burg
Document: https://help.ubuntu.com/community/Burg
Mailing list: http://groups.google.com/group/burg-devel
Hi,
No, you can have many menu, but you can only specify one to be auto
generated from menuentry items. You can construct the additional menus
manually.
> Is there any way to emulate sub menu
> behavior with panels (My panels always clip when they reach the
> borders of their parent, I'd like them to not be confined by the
> parent)?
By default, the submenu appears next to parent, the position is
calculated automatically. But you can config its location, there is an
alternative submenu template in the document page that display the
submenu full screen.
> Also, there any way of applying a class parameter to the
> widget that it's passed to (I tried 'parameters = "class=this.class"'
> and 'parameters = "class=class"')?
If the parameter is not specified in parameters, it's assumed to be a
property of the root widget, so you can skip settings like
class=class.
--
Bean
Project: https://launchpad.net/burg
Document: https://help.ubuntu.com/community/Burg
Mailing list: http://groups.google.com/group/burg-devel
Hi,
A menu is just a combination of panel, image and text, for example:
screen
{
panel
{
direction = left_to_right
panel
{
direction = top_to_bottom
image { halign=center image=icon1.png }
text { halign=center text=os1 }
command="true"
}
panel
{
direction = top_to_bottom
image { halign=center image=icon2.png }
text { halign=center text=os2 }
command="true"
}
}
panel
{
id = __menu__
Hi,
screen
{
panel
{
direction = left_to_right
panel
{
direction = top_to_bottom
image { halign=center image=menu1.png }
text { halign=center text=menu1 }
command="dialog_popup -r submenu_1"
}
panel
{
direction = top_to_bottom
image { halign=center image=menu2.png }
text { halign=center text=menu2 }
command="dialog_popup -r submenu_2"
}
}
}
submenu_1
{
panel
{
direction = top_to_bottom
image { halign=center image=icon1.png }
text { halign=center text=os1 }
command="dialog_popup -r submenu_11"
}
}
submenu_11
{
panel
{
direction = top_to_bottom
image { halign=center image=icon11.png }
text { halign=center text=os11 }
command="true"
}
}
submenu_2
{
panel
{
direction = top_to_bottom
image { halign=center image=icon2.png }
text { halign=center text=os2 }
command="true"
}
}
The -r option is used to indicate relative positioning, that is, the
submenu's location is calculated using current selected item.
BTW, you can use dump_config command in console to see how items
defined in menuentry are expanded in screen:
dump_config screen
The auto generated sub menu is using the same method
It uses similar method to implement sub menu, although it places all
generated menus under a menu_tree node, you can even use dump_config
to see its content:
dump_config menu_tree
command="dialog_popup -r submenu_1"
Hi,
Yeah, that's right.
Hi,
Currently, the position of sub menu is calculated by menu system, you
can't control its location. Or you can disable auto positioning and
specify its location manually, but in this case, all submenu appear in
the same place and not related to the current item.
I've thought of adding parameters to control the auto calculation as
well, but it seems there are a lot of controllable variables so i
decides to stick with simple method for now. Although, implementing
the behavior you described is not difficult, I'd look into it soon.
Hi,
The index is used to place multiple menu in one node, for example:
screen
{
panel
{
direction = left_to_right
panel
{
direction = top_to_bottom
image { halign=center image=menu1.png }
text { halign=center text=menu1 }
command="dialog_popup -r submenu 0"
}
panel
{
direction = top_to_bottom
image { halign=center image=menu2.png }
text { halign=center text=menu2 }
command="dialog_popup -r submenu 1"
}
}
}
submenu
{
panel
{
direction = top_to_bottom
image { halign=center image=icon1.png }
text { halign=center text=os1 }
command="true"
}
panel
{
direction = top_to_bottom
image { halign=center image=icon2.png }
text { halign=center text=os2 }
command="true"
}
}
This is used in auto generated sub menu, it'd reduce the number of top
level node.
System wide transparency is not implemented yet, but transparent png
file should work.
Oh sorry, the property name is actually
min_width/min_height/max_width/max_height.
Hi,
Scroll bar is not implemented yet.