How to make an ofxapp layout responsive?


#1

is there a way I can make an ofxapp layout responsive?


#2

I think there’s always a way, it just depends on how much time there is :slight_smile:

It also depends on the definition of responsive. A simple approach: don’t use any fixed sizes for any graphical elements, make every single position and size proportional to ofGetWidth() and/or ofGetHeight().

One step further is to detect if the screen is landscape or portrait, and change the layout accordingly.

A more advanced approach, with variable number of columns and the ability to zoom in and out, you might have to code yourself (unless someone knows of a c++ library or addon that does this). http://doc.qt.io/qt-4.8/scalability.html lists some things to consider.


#3

I am familiar with qml, thank you


#4

even though, sometimes binding qml to open frameworks, or vice versa, can be tricky, as the install scripts for open frameworks don’t always work