How do I activate an in-place editor for a grid cell that displays as a progress bar? - delphi

One of the cells in my DBTreeListView is bound to a repository item that is a progress bar.
I want to be able to edit the progress displayed by clicking on this cell. At this stage my application should change its cell to another repository item: a text field where I'll be able to insert a value. Once focus is changed to another cell, my progress bar should be displayed again, showing a new value. How do I do this?
DBTreeListView has column events OnGetEditingProperty and OnGetEditProperties. I'll probably use one (or both) of them, but can't come up with any good idea.

This can be simply. You should handle click on this progress bar and display editor over it. You need to handle scrolling and clicking in another place to get rid of editor. And in case that scrolling too far - editor should be hidden.
Steps:
Create hidden editor for progress
Handle OnClick for tree view item
Display editor and set focus
On editor enter (or tab) save progress information
On click on form or another part of tree view - hide editor (saving/discarding changes how specified by your policy)
On scroll tree view move the editor and when bounds of parent does not overlap bounds of editor - hide it
Best regards,
Vladimir

Related

Clicking an object visually doesn't select it in IB Xcode 7.3

Is there a way to visually outline the selected object in IB?. I noticed that when an object is selected in IB, the object shows selected in the Document Outline but it doesn't in the Design view:
However, if the object happens to have constraints, then there's a frame that gets drawn around it or at least the constraints are shown (depending on the Editor settings you have selected), but there are clues which object is selected in the Design view:
I know that if you click twice on the object, then a deep selection is made, but then you can't move the object; you can just act upon it to other actions but not moving it:
It looks like you have Resize Knobs disabled. These are normally on by default and would outline the selected view.
To enable them click Editor -> Canvas -> Show Resize Knobs in Xcode.

iOS - What do we call the type of menu which pops up, as seen when highlighting text

When you highlight text in iOS, a menu is shown giving options such as cut and copy, it floats above the text and is black. What is this called and how can i implement it in a tableview (to give options when a row is selected)
You mean this, this is a UIMenuController
https://developer.apple.com/library/ios/documentation/iPhone/Reference/UIMenuController_Class/
another bit of info:
http://nshipster.com/uimenucontroller/
How to use it:
https://www.captechconsulting.com/blogs/getting-started-with-uimenucontroller-in-ios-5
An actual example already coded up for you:
https://github.com/jszumski/uimenucontroller-example
It is called UIMenuController.
This menu is referred to as the editing menu. When you make this menu visible, UIMenuController positions it relative to a target rectangle on the screen; this rectangle usually defines a selection. The menu appears above the target rectangle or, if there is not enough space for it, below it.
You can also provide your own menu items via the menuItems property. When you modify the menu items, you can use the update method to force the menu to update its display.

In Xcode Interface Builder - why are the options in the Editor--->Arrange menu (containing Send to Front, Send to Back) often disabled?

What I'm trying to do is simple: bring a label in front of an image within a subview.
But all of the options for arranging are disabled/un-selectable when my label is selected. I find this happens often.
What could be the reason that I'm almost never allowed to change the z-axis of my objects in the Arrange menu? Is it a better practice to avoid this feature and set the order of views programmatically?
It can depend on how you have selected the label (similar to how the label can only be moved with the keyboard when selected in some ways).
A simple alternative is to look at the list of view in the pane on the left and to drag the views up and down to change the order.
It happens sometimes. In that situation, click the view or image you want to send back then you will see little square box at the edges of image from which you can re size your image, Just click on it once and then go to Editor > Arrange > Choose option according your need.

How to add control to the TRzToolbar

I have add TRzToolbar to the form. I want it to look like as shown in figure below.
I want to add control as shown in figure to the TRzToolbar..I right clicked TRzToolbar component on the form selected edit toolbar which bring in Toolbar editor with stock images as shown below.
In stock images it is not showing control like checkbox,drop down and radio button etc as shown in first figure. How to add these control to TRzToolbar?
The Toolbar Editor can only handle Toolbuttons. Instead using the editor, simply drop the desired control from the tool palette onto the Toolbar in the form designer.

How to select background views in a storyboard or xib

If I select a view with my mouse in a storyboard or xib, Xcode will select the front most view. I know that I can select the other views in the document outline, but if I want to grab a background view to move it with my mouse, the front most view gets selected again when I click in the storyboard.
I think there is a way to cycle through the views and select the ones in the back by holding down on some keys, but I can't find what it is. Does anyone know?
I'm using Xcode 4.6. I know that I can also move background views using the size inspector, but I'm looking for a way to position them with my mouse.
One way is to use the jump bar at the top of the editor. It's the control that shows the path of objects leading to the current selection.
Another way is to press control+shift and left click (or shift right click) an item. That shows you all of the objects under the mouse in a menu, and allows you to disambiguate the one you meant to select.
The good news: Place your mouse on the overlapped images, press and hold shift and right click the mouse. You should see the list of objects, select your object in the back. You can resize as you wish.
The bad news: you can only use the cursor arrows if you want to move it!
Select the view from the menu on the left of interface builder.

Resources