Reduced the number of tabs on the first page of the outer tab in the test program. This makes the uiArea tabs more readily accessible on all platforms and keeps the initial size of the main window down on OS X. Also fixed the rpath nonsense on the example makefile too.

This commit is contained in:
Pietro Gagliardi 2015-12-19 16:56:45 -05:00
parent 33d4217450
commit 16f22576ed
2 changed files with 14 additions and 6 deletions

View File

@ -21,8 +21,12 @@ SUFFIX = $(EXESUFFIX)
# TODO merge with the one in build/GNUmakefile.test
ifeq ($(TOOLCHAIN),gcc)
LDFLAGS += -L$(OUTDIR) -lui
# tell the dynamic loader to search in the executable path for shared objects
LDFLAGS += -Wl,-rpath='$$ORIGIN'
# see build/GNUmakefile.test
ifeq ($(OS),darwin)
LDFLAGS += -Wl,-rpath,@executable_path
else
LDFLAGS += -Wl,-rpath,'$$ORIGIN'
endif
else
# TODO is there an equivalent to -L?
LDFLAGS += $(OUTDIR)/libui.lib

View File

@ -47,6 +47,7 @@ int main(int argc, char *argv[])
uiWindow *w;
uiBox *page2, *page3, *page4, *page5, *page6, *page7, *page8;
uiTab *outerTab;
uiTab *innerTab;
int nomenus = 0;
int startspaced = 0;
@ -90,7 +91,7 @@ int main(int argc, char *argv[])
uiBoxAppend(mainBox, uiControl(outerTab), 1);
mainTab = newTab();
uiTabAppend(outerTab, "Original", uiControl(mainTab));
uiTabAppend(outerTab, "Pages 1-5", uiControl(mainTab));
// page 1 uses page 2's uiGroup
page2 = makePage2();
@ -111,14 +112,17 @@ int main(int argc, char *argv[])
page5 = makePage5(w);
uiTabAppend(mainTab, "Page 5", uiControl(page5));
innerTab = newTab();
uiTabAppend(outerTab, "Pages 6-8", uiControl(innerTab));
page6 = makePage6();
uiTabAppend(mainTab, "Page 6", uiControl(page6));
uiTabAppend(innerTab, "Page 6", uiControl(page6));
page7 = makePage7();
uiTabAppend(mainTab, "Page 7", uiControl(page7));
uiTabAppend(innerTab, "Page 7", uiControl(page7));
// page8 = makePage8();
// uiTabAppend(outerTab, "Page 8", uiControl(page8));
// uiTabAppend(innerTab, "Page 8", uiControl(page8));
if (startspaced)
setSpaced(1);