I want to show the 3 lines on map view annotation call out bubble.
That means I want add the one extra line with title, sub title in call out bubble.
Please give me the solution.
Related
I cannot figure out (or find an example) how to perform the following simple thing in the LibreOffice Calc 6.2:
I have a drawing shape (e.g. a simple rectangle) in a sheet (call it ShapeA) and a textbox shape in another sheet (call it TextboxB). I want to do the following: when I click on the ShapeA, the TextboxB must appear on the screen (without changing the current sheet, maybe in a dialog box) and then be closed with a mouse click.
I guess the macro associated with ShapeA could look something like this:
Sub Main
oDrawPage = ThisComponent.getDrawPage()
oTb = oDrawPage.getByName("TextBoxB")
oTb.show()
End Sub
Could someone advise what I should put into this macro to accomplish the described task?
UPDATE: What I want to accomplish ( in reply to Jim K.).
I have a very cluttered diagram with many shapes. Each shape has some textual information associated with it. There is not enough space on each shape or around it to contain this info. So there is must be a way to display this info about each shape. Also this information should be displayed in a preformatted way (it contains code and other structured info).
My plan is to create a textbox with the relevant information for each diagram shape, place these textboxes in other sheet and have a possibility, when viewing diagram, to click on any shape and view the associated info in the poped up textbox without leaving the diagram, and then close the textbox with a simple action (e.g. by clicking on it).
Does this task sound feasible to be realized with the LO's shapes and macros?
How about this: Put everything on the same sheet but keep the text boxes hidden until needed.
Use the following code adapted from https://ask.libreoffice.org/en/question/93050/how-can-i-hideshow-a-shape-of-my-spreadsheet-using-a-macro/.
Sub ShapeClickedA
ShowHideShape("TextBoxA")
End Sub
Sub ShapeClickedB
ShowHideShape("TextBoxB")
End Sub
Sub ShowHideShape(shapeName As String)
oDrawPage = ThisComponent.getSheets().getByName("Sheet1").getDrawPage()
For iShape = 0 To oDrawPage.Count - 1
oShape = oDrawPage.getByIndex(iShape)
If oShape.Name = shapeName Then
If oShape.Visible Then
oShape.Visible = 0 'Not Visible
Else
oShape.Visible = 1 'Visible
End If
End If
Next iShape
End Sub
If you haven't yet, set the names of the text boxes by right-clicking and choosing Name... Then right click on both ShapeA and TextBoxA and assign the macro ShapeClickedA. Do likewise for other pairs of shapes. The result works like this:
Before anything is clicked.
Click on ShapeA. (To close it again, click on either ShapeA or TextBoxA). ShapeB functions similarly.
It's also possible to display both at the same time.
I am following this example:
https://docs.mapbox.com/android/maps/examples/symbol-layer-info-window/
Also here:
https://github.com/mapbox/mapbox-android-demo/blob/master/MapboxAndroidDemo/src/main/java/com/mapbox/mapboxandroiddemo/examples/dds/InfoWindowSymbolLayerActivity.java
It is loading a number of points with descriptions from a file.
On line 271:
String geoJson = loadGeoJsonFromAsset(activity, "us_west_coast.geojson");
What I need is to do the same dynamically. I have the information already as features in the map. I can get Title and Description from there. What I need is to use GenerateViewIconTask and setUpInfoWindowLayer when this event is triggered: onMapClick.
So basically a user taps on the map, I get the coordinates and search in the map's features, get the lat/lng, title and description and show up a callout on the map.
I can handle tapping, getting the map's feature, extracting title and description. What I need to do to finish with showing a nice callout on this location with title and description.
Sorry for the late response. You can either show a label by setting the textfield property or (according to the docs) create an info window by setting the iconImage property to a string, like iconImage("{title}").
Sadly I've rarely used the latter as it never worked for me.
My annotation looks like this now:
As you can see the text is too long for it to be showed. How can i make a new sentence below? Or just make the annotation subtitle wider so i can see all the text?
I want it to say "Antal personer: 5. Riktning öst: 4. Riktning väst: 1."
But the best would be:
"Antal personer: 5
Riktning öst: 4
Riktning väst: 1"
I have not been able to find any information on how to make a new row in subtitle. I have seen something with /n but it does not work.
in iOS 9 we have a new property named detailCalloutAccessoryView
You can create a view and set as
annotationView.detailCalloutAccessoryView = tempView
Please check the link to get more details
MapKit iOS 9 detailCalloutAccessoryView usage
I want to edit corresponding labels when the user selects a row.
i have 3 labels in each row in my 1stView . i want to edit the text of those labels
navigating to the another view and there i need to edit those labels text.
one of my labels text is getting from UItextfield declared on the 2nd view and the other 2 labels text is getting from uibuttons title on the the 2nd view.
Now i want to show the labels text in my 2nd view for editing the text pf those three fields??
for more clear i will ellobrate
I have a table in my 1st view, when i click on add button am loading another view(2nd view) where it contains 1 textfield and 2 buttons. I am setting the text of these three fields to my 1stview my each tableviewcell has 3 labels created in each row.
How can i edit those 3 fields??
I would suggest you to make the required strings accessible in both Class1 as well as Class2. So that when you want to get the text from Class2 you can save those strings in your stringVariable and can thus pass on the values to Class1 as well..
After Question Edit:
I will again suggest you to take 3 string variable in class1 and make it accessible in class 2... While you go to class 2 in edit mode/ add new mode you can save the text of textfield and button titles in the 3 strings and can access the same in Class1 and display it in table's cell in Class1. Hope I make it more clearer now
Basically what I am trying to do is:
1) The user sets the number of choices he wants e.g. 3 choices which are "A", "B", "C"
[Done this]
2) The next view is loaded and the right amount of boxes are created, 3 in this case. The boxes need to be blank at first and then the user enters their choices into the boxes.
e.g. "A", "B", "C"
Note: I tried create multiple text boxes automatically, but I found that after about 6 boxes the screen wouldn't scroll and therefore looked very tacky
3)At a click of a button, one of the textboxes is selected randomly. The inputed data from this randomly selected box is then displayed in NSLog or Label or file, which i will then use in another view.
Thanks
Dan
Hey, you could make a scrollView out of the 2th view. That way, you can still automatically create textfields, and the screen will scroll. Check out this link for more information on how to create a scrollview. Perhaps you can make the scrollview's size dynamically (depending on how much textfields you have).
About selecting a random textfield, use arc4random() More about that can be found here.