Top bar Menu Issues

Hello all. I’ve been trying to make a system for adding icons to Roblox’s top bar Gui, which I’ve mostly succeeded at doing, however,

What I’m asking is; how would I detect when the top bar dropdown menu is open/closed? I’ve looked through a lot of the documentation for CoreGui and StarterGui and I can’t really find a way to detect this. Any help would be appreciated, images have been attached, Thank you.


1 Like

There is a property called TopbarInset, the width of this changes when you open that menu, this is a piece of code from roblox self:

This is how they intended for you to work with the new coregui, also this code is in the bottom of the post if youre wondering, they also show an example of how this looks like:

local GuiService = game:GetService("GuiService")
local Players = game:GetService("Players")

local screenGui ="ScreenGui")
screenGui.IgnoreGuiInset = true
screenGui.Parent = Players.LocalPlayer.PlayerGui

local frame ="Frame")
frame.BackgroundColor3 = Color3.fromRGB(0, 255, 0)
frame.Parent = screenGui

  local inset = GuiService.TopbarInset
  frame.Size =, inset.Width, 0, inset.Height)
  frame.Position =, inset.Min.X, 0, inset.Min.Y)

Anyways just put your button in the frame and it automatically changes position with it

Also an issue you can encounter while implementing this:

1 Like

I’m not sure if you are aware but there is an open source module for stuff like this

But if you want to make your own system, then schaap5347 explained TopbarInset very well