You should calculate the size according to user's screen size when designing a GUI. Using magic numbers here would work well for a fraction of users, but would be terrible for some.
For example, you first get the user screen width and height and then you decide what fraction of screen size is needed for each element. Then you set the size using a fraction of screen width and height.
This would be the best practice because any user with any screen size would experience something the same!