Note that there are some explanatory texts on larger screens.

plurals
  1. POBoxLayout in Cocoa
    primarykey
    data
    text
    <p>Originally, I wanted to ask how to create user interfaces with cocoa programmatically, i.e. without using interface builder. But it seems that someone else has already <a href="https://stackoverflow.com/questions/717442/how-do-i-create-cocoa-interfaces-without-interface-builder">asked this question</a> and the answers didn't help me.</p> <p>So I'll ask a different question, that I hope will indirectly help me answer the previous question. Here it is:</p> <p>(QUESTION_START)</p> <p>How do I create an Objective C class that is equivalent in functionality with the <a href="http://download.oracle.com/javase/tutorial/uiswing/layout/box.html" rel="nofollow noreferrer">BoxLayout class</a> in Java? (Just click the link, the image on that page says everything you need to know about BoxLayout.)</p> <p>(QUESTION_END)</p> <p>Any help in the right direction will be appreciated!</p> <p>There are a few sub tasks that are connected with the question, e.g.</p> <p>"How do I ask a user interface element (e.g. a button) how large it wants to be" (before it has been drawn to the screen). To draw it on the screen you have to already know its size, don't you? Obviously, the interface builder application has figured out a way to do this.</p> <p>I know that many Cocoa developers think it's a stupid idea to even try what I want to do. Let me tell you: I know the reasoning behind that opinion. Right now, laying out controls without interface builder sucks, because there is nothing that comes even close to a layout manager in cocoa. But if you think my question is stupid, please DONT answer. The whole internet is full of explanations why you would never want to create UIs with code in cocoa.</p> <p>Thanks!</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload