how to give space between two image buttons - blackberry

How to give space between two image buttons on the screen of BlackBerry 4.7?

you should try setMargin:
imageButton1.setMargin(spaceUp, spaceRight, spaceDown, spaceLeft);

Related

iOS - images stretched in stack-view

Here is my status I created stack-view with two sub views --> vertical and horizontal stack-view
the horizontal view contains 3 button
check image below
my issue when I set background to button its stretched as appear in image
my tries to fix this issue ,
1- set view mode to aspect-fit
2- increase spacing between button
3- set fixed width and height to one of buttons as all obey
but unfortunately all my tries doesn't work , any one could guide me to fix my issue thanks
Have you try to use SetImage Instead of BackgroundImagethat will fix the issue else use the proper image with proper size that you want to implement based on your requrement. see the following difference between setImage and SetBackgroundImage
Here you need to change your image size with your stack view's button image that will be fix your issue and for using stack view following is a good link: https://www.raywenderlich.com/114552/uistackview-tutorial-introducing-stack-views

Place buttons and labels on top of UIImageView in Xcode 6

I'm new to iOS development and I'm just getting my way around Xcode 6 working with Swift, but I'm hitting small blocks here and there so please understand why question may be very basic.
My issue is I have a background image (UIImageView) which is placed within a View within a ViewController. All I want is to be able to drag and drop other type of objects like buttons or labels on top in the designer section. When I have the designer view I see these buttons and labels visible on top of the UIImageView, but when I run the project in the iPhone simulator all these objects disappear and I just see the background image (UIImageView). Is there something I'm missing here?
Thanks in advance.
You should read auto layout Apple document https://developer.apple.com/library/ios/documentation/UserExperience/Conceptual/AutolayoutPG/
Basically its the way you describe position relatively, say you want to align button center on the UIImage, in this case you define 2 constraints vertical align and horizontal align.

Increase touch sensitivity of iPhone app programmatically

I am using too many number of images for buttons in my project. I found some issues while doing device test. App couldn't detecting the finger tapping sometimes. I need to increase the touch sensitivity programmatically to resolve this issue.
Like apple documentation says:
Make it easy for people to interact with content and controls by giving each interactive element ample spacing. Give tappable controls a hit target of about 44 x 44 points.
Make the button tappable size at least 44x44 pixels and it should work.
More informations here
https://developer.apple.com/library/ios/documentation/userexperience/conceptual/mobilehig/LayoutandAppearance.html
it's not possible, but you might have smaller action button which you could resize little more or you can have bigger transparent action button behind your smaller action button so you can get what you are looking for!
Add images to button like this -
here you can see the button border are larger that image size, so you can increase the touch area of button in this way.
For further image adjustment inside button, you can use image insets, which are also present in the same inspector in xib.

How to make gallary view at bottom in blackberry

The nexGTv – Mobile TV for touch phone app has a scrolling horizontal field manager that I want to create in my own app.
It has image buttons at the bottom of the screen, horizontally. These images slide to the right and to left. The initial focus is the horizonal center image, then each image has 10 pixels of padding to the next image. What should i use for this?
I can understand your question, but i can not give you related code but i can tell you the logic behind this. To do this you first set a image at center and set bottom padding 10 pixel then fill images left side and right side. You have to do this in paint method. If you are a Blackberry Developer then you can understand it and try to do it. All the work perform in paint method, by using loops you can do this. This work con not be done by Picture-Scroll-Field because you want middle image with extra padding.

How to scroll images horizontally on a blackberry

I want to scroll the images horizontally with its title and description, I had done using picture scroll view but it shows only title that too at the bottom of the screen but i want to display it at the top and with the title i want to display its description also, please help.
And another option i had tried using the interface scrollchangelistener by using that i displayed the images with its title and description on the top of the screen but it scrolls in vertical direction i am unable to do it in horizontal. Please help i am in great difficulty since last few days, Please help.
Use HorizontalFieldManager and add the contents in it
It will work
Use Manager.HORIZONTAL_SCROLL as argument in it
eg:
HorizontalFieldManager hfm=new HorizontalFieldManager(Manager.HORIZONTAL_SCROLL);
This BlackBerry support forum thread will help you, in addition to the PictureScrollField documentation.
how to show images in horizontal scroll field in blackberr

Resources