I'm trying to develop a GTK desktop application.
I want to display an image and make some clickable areas on the image. For this reason, I'm using GtkFixed container to put the image and clickable areas(GtkEventBox is used for areas). After the user clicks on a GtkEventBox, I want to display a box in the clicked area. For this reason, I have thought to use GtkVBox to make a box to display.
The problem is that GtkVBox is not visible inside a GtkFixed container parent. So I am stuck at that point. Is it possible to use GtkVBox inside GtkFixed? If not, what is the proper method of doing this job?
I found the answer, it was a mistake that I used gtk_widget_show to make container visible instead of gtk_widget_show_all. It works now
Related
I have a vertical swiper where in one of the slides I have a box with overflowing Y content, I want the user to be able to scroll vertically within the box. But in both dektop and android mousescroll is not working. No scroll event is generating from within the box, and scroll is interpreted as swiping. I also have a multiline text field inside same slide but I am able to scroll in that, so it must be possible. How can I make it work the way I want to?
I have developed app using Codename one.I want to set specific height of dialog because my text overidden while displaying message in dialog body .what should I do for that?
Thanks in Advance?
I have added image in which first image is original image and second one is cut image which is displaying on screen while using infinite progress bar. my code is "Dialog ipDialog = new InfiniteProgress().showInifiniteBlocking(); ipDialog.Dispose()" I want whole image on screen like original image.
can you help me to solved this ?
You can use the Dialog show method that accepts int values to determine the distance from the edges. But normally this is a matter of the text sizing and dialog construction.
Also make sure you are showing the Dialog from the EDT thread.
I'm not sure if this is the right place to ask because I dont have any code to show. I'm actually looking for ideas on possible ways to solve my problem.
I have an app that displays the grid on the screen when the media query has a min width of a tablet.
But when the view is in mobile mode I don't want to show the grid. Instead I have a drop down menu which has a grid option. When selected will be show in a paper-dialog (pop up)
The problem is I have to create two grids (vaadin-grid) and show the appropriate one based on the view. Is there a way to have only one grid? Can I put it in a paper-dialog but not pop-out when in tablet and desktop view?
Thanks in advance
If your grid element has every custom property then that is an element in the DOM, so you can move it into the dialog if thats needed using javascript:
let myGrid = this.$$('#myGrid');
let myDialogContent = this.$$('#myDialogContent');
Polymer.dom(myDialogContent).appendChild(myGrid);
Also if you think it a different way, then you can hide the grid outside of the screen and you can slide that in when it's needed like a drawer panel and you dont need to move the element at all in the DOM.
By the way for programming question stackoverflow has the https://softwareengineering.stackexchange.com/ site, but I think it is Ok to send it here.
I am working on Creating some objects in a container withing a from in codenameone. I am moving objects every 2 seconds, the objects are moving but the container is unable to display the objects. It displays only when i click the sidemenubar and it shows objects on the container. If SideMenuBar is closed , it again disappears.
I am posting 2 images which describes the problem.
I used repaint(), revalidate() and also show() but it is showing the same thing. Please Help!!
Its hard to tell what you are doing but I guess you just paint the green background on top of these images that you draw at some point. The side menu bar converts the form to a screenshot when sliding out so you are seeing a frozen state of the form not the actual view.
I'm trying to create Custom Form configuration with scrollable TitleArea. The Form (black) has a BoxLayout.Y_AXIS Layout in BorderLayout.CENTER (blue). StatusBar (green) stays in BorderLayout.NORTH (green), when rest of the TitleArea (cyan) is in the first position in BoxLayout.
removeComponentFromForm function is unavailable for using in extended class. How can I remove components from Form to removing titleArea from BorderLayout.NORTH?
Why use the title area at all? Why not just add a component to the top of the box layout Y and style it as a Title that way you can scroll it out?
You can also use the new Toolbar API that includes many abilities to fade out the title as you scroll etc. See:
http://www.codenameone.com/blog/toolbar.html
http://www.codenameone.com/blog/cats-in-toolbars.html