I am trying to design a prototype for a web page. This web page can be on anything from full screen on a desktop computer to a small cell phone. And so the frame width can vary from 20" wide to 3" wide.
Is there a way in Figma to have it move controls so that on a wide framework it will have:
First name: [_____________________________]
while on a cell phone size, it will adjust to:
First name:
[________________]
In a perfect world, it would both move the editbox to the next line and reduce the editbox to the width of the screen if the editbox was wider than the screen.
And I'd like to have it handle larger cases. Such as wide screen:
First name: [_____________________________] Last name: [_____________________________]
Medium screen:
Last name: [_____________________________]
First name: [_____________________________]
And small screen:
First name:
[_____________________________]
Last name:
[_____________________________]
Resizing one form field, depending on parent container width:
This is possible in Figma using either Constraints, or Auto Layout features.
Dynamic wrapping of form field elements, depending on parent container width:
You are trying to simulate Responsive Design and/or flex grid layout on Figma, as if it was already a fully implemented web page viewed in a browser. Form field elements will wrap or get displayed next to each other, depending on the width of the page / browser.
Figma doesn't support this yet. You will have to illustrate both layouts, and then instruct the devs to implement the layouts as responsive design modes for the same page.
As a workaround, you can create a Smart Animation of the form fields wrapping / unwrapping as the page width is changing. It's not an interactive prototype, but it communicates the idea of applying your Responsive Design layout for your form fields.
Related
I saw a viz in the company's repository, and I wish to replicate one of the feature.
The viz is consist of several pages with an introductory page. The introductory page contained a lot of information with a scrollable canvas, while other detail page had a fixed-to-window way of presenting data, showing each segment in one screen without the overall scroll bar.
What I want to know is how to only make one or part of the pages in the dxp file able to enable the scroll bar (larger canvas height), while the rest having the fit-to screen way of displaying the viz. Any approach will be appreciated.
PS:
The Document Property→General→Visualization area size→Custom size method changes the canvas size of all visualization table. Which is not able to fulfill this feature, as this property changes the canvas size of all pages in the dxp file, which is not what I expected.
sounds like they used a Text Area but it's hard to tell without seeing the document.
you can insert a Text Area the same way you do a visualization (via the toolbar or the main menu). you can then right click the Text Area to edit it either with the WYSIWYG editor or in raw HTML. Text Areas will show scrollbars to match the length of your content.
I am using FullPage JS to display a few sections. On the desktop, it works perfectly.
However, Some sections have quite an amount of content. On smartphones, part of the content of these sections is covered. Put another way, I am only able to see part of the content of these sections when I scroll (I already used media queries to reduce content display on smartphones, but these sections do have more content than what a full screen can display on smartphones).
I need the usual FullPage JS to work for me on the desktop. However, can I disable full screen display on smartphones and simply display a list of sections as a long page on smartphones? Did anyone do this before?
fullpage.js provides options for it such as responsiveWidth and responsiveHeight that will turn off auto scrolling under a given value in px.
Combine those with the class fp-auto-height-responsive and you'll get what you want.
All of this is detailed in the docs.
Responsive auto height sections
A responsive auto height can be applied by using the class fp-auto-height-responsive. This way sections will be full height until the responsive mode gets fired.
responsiveWidth: (default 0) A normal scroll (autoScrolling:false) will be used under the defined width in pixels. A class fp-responsive is added to the body tag in case the user wants to use it for his own responsive CSS. For example, if set to 900, whenever the browser's width is less than 900 the plugin will scroll like a normal site.
responsiveHeight: (default 0) A normal scroll (autoScrolling:false) will be used under the defined height in pixels. A class fp-responsive is added to the body tag in case the user wants to use it for his own responsive CSS. For example, if set to 900, whenever the browser's height is less than 900 the plugin will scroll like a normal site.
I have just upgraded Unity to version 4.6 and tried to create a button by Create -> UI -> Button.
However, this button doesn't show up in #Screen tab but it does in Game tab.
Please look at the screen shoot below:
Another question is: The default width and height when creating a new button is 160 x 30. When I change the source image with my own image button, I have to change the width and height parameters in rect transform. Is there any faster way to automatically obtain new width and height based on the image which I insert?
Thank you very much!
First, double click the button in your hierarchy and see that it indeed does not show in the Scene view, excluding any kind of zoom problem. (By the way, I'm assuming you mean "Scene" and not "Screen", right?) Things in different cameras or canvases might have very different scales but appear correctly in the Game view. I don't know how used you are to Unity, so I'm sorry if this sounds obvious. :)
Next, check the dropdown labeled "Layers" on top of Unity's editor, to the right of the Play, Pause and Step buttons. See if the layer of your button (which in this case is "UI") is visible. It should have an open eye icon next to it.
Regarding your other question, after dragging your sprite to the Image component, you can press the "Set Native Size" button, which will set the size of your object to the dimensions of your Sprite. Regarding the new UI, I think this is as automatic as it gets. Note that "Set Native Size" will only appear if your Image type is set to Simple (probably what you want) or Filled in the component.
I had the same problem before and here's a possible solution.
By default, the editor camera (Scene Tab) renders the World Space,
so your Canvas component's render mode should be set to "World Space".
The problem may only occur when you're trying to (or supposedly) render your UI in Screen Space - Overlay or Screen Space - Camera in the Canvas component.
So if you want to properly edit UI objects in the scene tab/window; set the Canvas component's render mode to World Space.
We don't have this problem in Unity 4.x before because I think Unity automatically renders any render mode from the Canvas component, however, that doesn't happen in Unity 5.x. I'm guessing it's either intentional that they do that or it's a bug on Unity UI feature.
I'm have some data output text boxes (text boxes with no border and with the same background as the rest of the window) that I'm trying to align with a standard edit control + spin button, to represent a column of numbers, one of which can be edited:
I can manually align these in the Delphi / C++Builder form designer, but when I then view the form on a different version of Windows or at a different DPI, the text is no longer right-justified, presumably because of differences in the spin button spacing, borders, etc.
I can use EM_GETMARGINS to determine the width of the spin button, but how can I determine the size of the edit control's margins and borders? I've tried various combinations of EM_POSFROMCHAR, ClientToScreen, GetSystemMetrics(SM_CXBORDER), GetSystemMetrics(SM_CXEDGE), and GetThemeMargins, but so far, I can't find a combination that works and makes sense.
More details:
Environment is Delphi / C++Builder XE2.
The data output controls are TEdits with BorderStyle bsNone.
The edit + spin button is a TJvSpinEdit. From viewing its source, it uses EM_SETMARGINS to allow space for its spin button.
Use the Win32 API GetWindowRect() and GetClientRect() methods. The bordering will be the difference between the two rectangles. That will only give you the bordering, though. There could be extra spacing inside the client area.
I am working on a data entry application and I am considering using a fluid layout approach ala Swing and Silverlight where the controls resize based on the window size. My question is simple: what feedback if any have you received from users on each of these approaches? Screen size aside, I will still have a vertical scroll in place so I am wondering if I would be best served to simply go the fixed route and absolute position/size content.
Do not go the fixed route. If the user resizes the window, they do so for a reason. The widgets should resize appropriately. I can think of no valid reason to ever use a fixed layout except in vey specialized circumstances.
That being said, don't have a layout where input fields wrap. That would be very disconcerting. Just let your widgets grow and shrink naturally.