Last updated: 2023-05-11
DAB-Z v2.x thread is here
This thread is discussing the (now "legacy") DAB-Z v1.x versions...
Release notes of currently active release on Google Play 1.9.127
Release notes of currently active PUBLIC BETA on Google Play: 1.9.127
If you want to become beta user, subscribe in Google Play or open this link from the device : https://play.google.com/apps/testing/com.zoulou.dab
The app is available in Google Play named DAB-Z with package name "com.zoulou.dab".
It can be installed in parallel to any original preinstalled DAB+ Player.
Get DAB-Z on Google Play
Get previous versions on Apkpure
Compatible devices:all DAB USB dongles with VID/PID = 16C0/05DC (decimal 5824/1500) ("VOTI", "Van Ooijen Technische Informatica", "shared ID for use with libusb", "[email protected]")
Examples (for sure not complete!)
XTRONS USBDAB01
Joying DAB+
Pumpkin Y0251
Hotaudio Dasaita DAB+
(and dozends or hundreds more, they are all quite the same, if not equal.)
Use this link to find out more
NOT SUPPORTED:* Any SDR ("Software Defined Radio") devices (e.g. based on Realtek RTL2832U R820T)
* Fulljoin adapter
* Dension DAB+U
* Dasaita DAB box
Frequently asked questions FAQ:DAB-Z's expected behavior regarding Play/Pause, Mute/Unmute, Navi App announcements
Q: Does DAB-Z support fallback to FM Radio?
A: No and it is not planned due to technical reasons.
Q: Why do some stations appear several times in the list but have all the same content?
A: This is an annoying behavior of the broadcasting stations. DAB-Z does not lump them together to give the user the choice to pick one into the favorites list that has the best signal strength.
Q: Is it possible to add a sort of buffer to bridge short reception outages and therefore interruptions of audio, e.g. while driving through a tunnel?
A: No. DAB is a real-time, live (but digital) broadcast (same as old-style TV and FM radio), in contrast to streaming. The broadcasted data that is lost due to missing reception cannot be recovered or re-requested later. Also, DAB cannot be read-ahead in contrast to streaming. An app therefore cannot create a buffer of "future" data in order to have data locally, which can then be used to bridge the loss of reception.
For testers ...... that want to actively support me and help everyone to have a better DAB-Z app:
If you encounter an issue with DAB-Z, I will maybe ask you to provide a) logcat logs or b) raw recordings.
a) logcat logs are created by pressing the logcat button in DAB-Z Settings -> Info (at the very bottom)
A zip file is created and you will be able to choose what to do (send via Email, add to Google Drive, etc...). Get this zip file to me somehow.
If I additionally ask you to enable "OMRI verbose logging", then follow these steps before creating the logcat as above:
1. Enable Developer Menu: tap 7x on DAB-Z Settings->Info->Version , then go back, a new menu item appeared "Developer options" at the very bottom
2. Enable OMRI verbose logging
3. Close DAB-Z
4. Reopen DAB-Z
... reproduce the issue ...
5. Create the logcat DAB-Z Settings -> Info (at the very bottom)
b) raw recording are created by this procedure:
raw recordings are done using this procedure:
1. Enable Developer Menu: tap 7x on Settings->Info->Version , then go back, a new menu item appeared "Developer options" at the very bottom
2. Enable OMRI raw recording (you don't need to activate verbose logging)
3. Close DAB-Z (raw recording enable/disable requires a restart of DAB-Z)
4. Reopen DAB-Z
... reproduce the issue ...
6. Go to DAB-Z Settings and disable OMRI raw recording. Restart DAB-Z again.
Afterwards, files with ending .raw exist in:
<internal memory>/Documents/DAB/rec/
Download them all from the head unit, zip them and send to me.
YHX-DAB+V170425_zoulou-20170521
Updated version YHX-DAB+V170425_zoulou-20170521
Change log:
- Some icons by cruiser12 (china-rns.com)
- Avoid repeating USB permission request on Android 6
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Been looking for an alternative dab+ app and you have created a great looking app. Just installed the new version looks so much better than the original, not keen on the green though if I'm being picky.
The problem I had with the original dab+ app was the signal would be full then completely drop out and I would have to close the app and then reopen to get the station to play. This could happen 4 or 5 times during my 20 minute journey to work, it was so annoying I've used FM radio for months.
I have had only one dropout so far with your updated app so far so good. Many thanks for all your hard work hope to see more improvements.
Sent from my HTC One M9 using Tapatalk
I really appreciate this effort! Obvious that whoever makes the original app doesn't know anything about how DAB works and what features users want. Will download your latest patched version and try using DAB again. I've relied on internet radio instead as the original app is close to useless with the horrible reception and crap interface.
Hey Zoulou many thanks for the great app.
Is it possible to get station logo to show in UK ?
Thanks
I am sorry that the slideshow feature (aka station logos) does not work in UK. However, I am unable to fix this, because decoding of the slideshow is done inside a libdab.so, which I am unable to change. I can only do changes in Java code and on the layout.
I assume that your original DAB+ App also does not show any station logo, right? I suggest then you contact your dealer and tell that the DAB App that comes with the device (or stick) does not show any station logo. The only chance to get this fixed is to report these bugs to the guys that develop this piece of crappy DAB App.
Great that you are trying to make this crappy app a bit better. In the past i made some modifications in the layout in this app for myself. I also found some icons or code which pointed in the direction of adding favorite radiostations. They never integrate it. Can you make this?
I also tried to integrale a lockscreen in this app, so Automate Will show the radiostation picture when playing. Unfortunatly i couldnt het It to work. Maybe you can look at it of you have the time.
Keep up to good work. Looking forward to your next release!
Hi thank you very much for your release!
With the version shipped by malaysk rom I had real problems. Every time the app was moved to background playback began to stutter...
This issue is now gone! Thanks!
One small request: Could you add a higher resolution app icon? The current one looks pretty crappy since the resolution is too low.
Thank you!
Can you show a screenshot of what you mean with the too low resolution icon?
The icon an text is very blurry. see the attachment
Another question, could it be that the app doesn't display images which a transmitted by the station?
freii said:
The icon an text is very blurry. see the attachment
Click to expand...
Click to collapse
You are right. I will change the icon in my next release. I don't have this icon in a higher resolution.
freii said:
Another question, could it be that the app doesn't display images which a transmitted by the station?
Click to expand...
Click to collapse
Some stations broadcast a complex slideshow (aka station logo), which this app cannot decode. Example: Bayern 3. Whereas Antenne Bayern is decoded fine. (I see you are from Bamberg )
Thank you.
The application works fine, but as with all the applications I have tried, I have no signal on my Erisin ES6046B.
realzoulou said:
Some stations broadcast a complex slideshow (aka station logo), which this app cannot decode. Example: Bayern 3. Whereas Antenne Bayern is decoded fine. (I see you are from Bamberg )
Click to expand...
Click to collapse
Ah okay I will check that out.
Just noticed because on my RK3188 device on "Radio Galaxy" the covers of the currently playing track was displayed.
Switched over to a PX5 device now and installed your mod right away because of the stuttering in the default app. So I don't really know if it would have worked with the default malaysk px5 app.
But this isn't that important to me, just noticed that it isn't working anymore.
---------- Post added at 14:18 ---------- Previous post was at 14:17 ----------
macandnews said:
Thank you.
The application works fine, but as with all the applications I have tried, I have no signal on my Erisin ES6046B.
Click to expand...
Click to collapse
Which usb dongle are you using and what kind of antenna?
freii said:
Which usb dongle are you using and what kind of antenna?
Click to expand...
Click to collapse
I have this tuner DAB + USB with the antenna delivered with that I put on the roof of my car to give a try.
http://www.ebay.fr/itm/162249572594?_trksid=p2057872.m2749.l2649&ssPageName=STRK%3AMEBIDX%3AIT
I have the same USB receiver.
But I replaced my antenna on the roof with this one: https://www.amazon.de/gp/product/B00IRWQ06G/ref=oh_aui_search_detailpage?ie=UTF8&psc=1
Because all the other antennas I tried didn't work. Now with this antenna I have full reception nearly all the time.
Chapeau!!!
Great work so far.
I just have the same issue with the original app, that the album pic is too small. This seems to be related to my screen size/DPI settings on my device.
I am using an Android TV box which is connected by HDMI to my Pioneer AppRadio SPH-DA110.
The pioneer has a 7" display and the DPI settings of my box is set to 480DPI.
My solution was to change some settings in the player.xml:
Code:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout android:orientation="horizontal" android:id="@id/relative_layout_main" android:background="@drawable/backgroud2" android:layout_width="fill_parent" android:layout_height="fill_parent" android:baselineAligned="false" android:weightSum="10.0"
xmlns:android="http://schemas.android.com/apk/res/android">
<LinearLayout android:orientation="vertical" android:id="@id/left_area" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_marginLeft="10.0dip" android:layout_weight="4.0">
<LinearLayout android:orientation="horizontal" android:layout_width="fill_parent" android:layout_height="wrap_content" android:layout_marginLeft="10.0dip">
<LinearLayout android:gravity="center|left" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_weight="9.0">
<ImageView android:layout_gravity="center|left" android:id="@id/signal_level" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginTop="0.0dip" android:src="@drawable/signal_0" android:contentDescription="@null" />
<Button android:gravity="center_vertical" android:id="@id/bt_record" android:background="@drawable/record_start_selector" android:visibility="gone" android:layout_width="wrap_content" android:layout_height="wrap_content" />
</LinearLayout>
<LinearLayout android:gravity="center" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_weight="1.0">
<TextView android:textSize="16.0sp" android:textColor="#ffffffff" android:id="@id/service_name" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/service_name" />
</LinearLayout>
</LinearLayout>
<LinearLayout android:gravity="right" android:orientation="horizontal" android:visibility="visible" android:layout_width="fill_parent" android:layout_height="wrap_content">
<LinearLayout android:gravity="left" android:layout_width="0.0dip" android:layout_height="fill_parent" android:layout_weight="1.0">
<TextView android:textSize="10.0sp" android:textColor="#ff808080" android:layout_gravity="center" android:id="@id/service_freq" android:paddingLeft="30.0dip" android:visibility="visible" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="service freq" />
</LinearLayout>
<TextView android:textSize="10.0sp" android:textColor="#ffffffff" android:layout_gravity="center" android:id="@id/service_pty" android:visibility="gone" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginRight="30.0dip" android:text="service pty" />
<Spinner android:textSize="10.0sp" android:textColor="#ffffffff" android:entries="@array/pty_array" android:layout_gravity="right" android:id="@id/pty_spinner" android:visibility="gone" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginRight="10.0dip" android:spinnerMode="dropdown" style="@style/customSpinner" />
</LinearLayout>
<LinearLayout android:gravity="center" android:layout_gravity="center_horizontal" android:background="@drawable/backgroud_text_area" android:layout_width="400dip" android:layout_height="250dip" android:layout_marginTop="1.0dip" android:layout_weight="8.0">
<ImageView android:id="@id/mot" android:layout_width="380dip" android:layout_height="230dip" android:src="@drawable/radio" android:contentDescription="@null" />
</LinearLayout>
<LinearLayout android:layout_gravity="center_horizontal" android:orientation="horizontal" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginTop="1.0dip" android:layout_weight="2.0">
<Button android:layout_gravity="center_vertical" android:id="@id/bt_prev" android:background="@drawable/previous_selector" android:layout_width="wrap_content" android:layout_height="wrap_content" />
<Button android:layout_gravity="center_vertical" android:id="@id/bt_scan" android:background="@drawable/scan_selector" android:layout_width="wrap_content" android:layout_height="wrap_content" />
<Button android:layout_gravity="center_vertical" android:id="@id/bt_next" android:background="@drawable/next_selector" android:layout_width="wrap_content" android:layout_height="wrap_content" />
<Button android:layout_gravity="center_vertical" android:id="@id/bt_pty" android:background="@drawable/pty_selector" android:layout_width="wrap_content" android:layout_height="wrap_content" />
</LinearLayout>
<LinearLayout android:gravity="center_horizontal" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="10.0dip" android:layout_marginTop="1.0dip" android:layout_weight="1.0">
<com.ex.dabplayer.pad.activity.MarqueeText android:textSize="18.0sp" android:ellipsize="marquee" android:id="@id/dls2" android:scrollX="4.0sp" android:visibility="gone" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="" android:singleLine="true" android:marqueeRepeatLimit="marquee_forever" />"
<TextView android:textSize="18.0sp" android:ellipsize="end" android:id="@id/dls" android:visibility="gone" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="" android:singleLine="true" />
<TextView android:textSize="18.0sp" android:ellipsize="marquee" android:gravity="center_horizontal" android:id="@id/dls_scroll" android:focusable="true" android:focusableInTouchMode="true" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="this is dls" android:singleLine="true" android:marqueeRepeatLimit="marquee_forever" />
</LinearLayout>
</LinearLayout>
<LinearLayout android:orientation="horizontal" android:background="@drawable/backgroud_text_area" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_marginTop="20.0dip" android:layout_marginRight="20.0dip" android:layout_marginBottom="20.0dip" android:layout_weight="6.0">
<ListView android:scrollbarAlwaysDrawVerticalTrack="true" android:id="@android:id/list" android:paddingTop="20.0dip" android:scrollbars="vertical" android:layout_width="fill_parent" android:layout_height="wrap_content" android:listSelector="@drawable/list_selector_background" android:stackFromBottom="false" android:transcriptMode="alwaysScroll" />
</LinearLayout>
</LinearLayout>
May be you have another idea to fill the picture background?
So the original and my modded app show a very small album picture (slide show in DAB terms), did I get this right? Maybe you could attach a screenshot?
realzoulou said:
So the original and my modded app show a very small album picture (slide show in DAB terms), did I get this right? Maybe you could attach a screenshot?
Click to expand...
Click to collapse
Yes, exactly... Will do a screenshot tomorrow on my commute.
Thanks again for the great mod
Can I suggest some small UI design changes? I modded the UI slightly myself a while back and thought the player looked much better without the "glow" frames around the slideshow and channel list. They don't need to be replaced at all, just removed. It would also look a lot better with some material design buttons instead of those 90's web design ones (previous, next, search etc).
Great mod, thank you very much
This version also shows Norwegian info text with correct font, something the original app did not.
I agree with nyogtha on the removal of the glow frame.
PTY is very useful, but favorites would be even better. Perhaps just an option to edit a file with the channel numbers to display and then add an extra PTY category named "My Favorites" or something like that to select the channels defined in the file?
Related
Hey guys,
I'm in the process of writing my first android app and something really strange is happening. I'm using a TabletLayout with the first two rows have spinners. On the third row, however I have an EditText box. Now, whenever I type in the text box, the spinners start to move in unison to the right. I have no idea what could be causing this and I don't even know where to look so I'd really appreciate your help.
Sorry for the horrible video quality. I didn't want to install video capture software on my work computer(yes, this is for work though this app is totally just to get me familiar with the tools) and I'm running MM's Gingerbread rom on my N1 which doesn't have hd video recording yet.
Here's the xml file
Code:
<?xml version="1.0" encoding="utf-8"?>
<TableLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:stretchColumns="1">
<TableRow>
<TextView android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:text="Convert from:"
android:gravity="left" />
<Spinner android:id="@+id/from"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:gravity="right"/>
</TableRow>
<TableRow>
<TextView android:layout_width="wrap_content"
android:layout_height="fill_parent"
android:text="to:"
android:gravity="left" />
<Spinner android:id="@+id/to"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
/>
</TableRow>
<TableRow>
<EditText android:id="@+id/value"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="Enter value"
android:gravity="right"/>
</TableRow>
<TableRow android:gravity="right">
<Button android:text="submit" android:layout_height="wrap_content" android:layout_width="wrap_content" android:textSize="24dip" android:id="@+id/submit" android:gravity="center|right" android:layout_gravity="right"></Button>
</TableRow>
</TableLayout>
Thanks so much,
Samuel Maskell
apparently embedding the video didn't work
here's the link
http://www.youtube.com/watch?v=D7IfVcGu3Ig
Here you go, under EditText, replace
Code:
android:layout_width="wrap_content"
with
Code:
android:layout_width="fill_parent"
well that was simple..
worked like a charm
Thanks,
Samuel maskell
smaskell said:
well that was simple..
worked like a charm
Thanks,
Samuel maskell
Click to expand...
Click to collapse
No problem, glad i could help
Hi, first post here & I did search for an answer first
I'm trying to add a menu to my app, in my onCreateOptionsMenu method I can use
menu.add(0, 1, 0, "Text1");
menu.add(0, 2, 0, "Text2");
etc
It works OK & when I press the menu key it pops up, the onOptionsItemSelected method correctly detects the item selected.
If I try to use the MenuInflater on an XML file, it does not work. When I press the MENU key, it pops up a menu with blank buttons - no text or icons & the number of buttons corresponds to the number of ITEM entries in my XML. The XML looks valid .
Any ideas where I'm going wrong. I would paste the code, but the forum says I cant until I've made more posts.
Thanks.
Still new to this myself, but in my recent menu tries, i had to put in a TextView into the xml to tell it what to say.
<TextView
android:text="@string/menu_button1" />
And define the name you want on that button under the strings file.
<String name="menu_button1">New Game</String>
I may be completly off so take what Im saying with a grain of salt lol
Hmmmm, tried that & it didnt work either. Thxs for the suggestion.
Not a problem the book i have at home had me do some menus, i could post the books complete code later maybe i missed something with what i told you. Its in pdf form so it wouldnt be a big deal. Ill be getting home in around 3 hours.
Maybe its a combination of button and textview together to actually make it work. It was pretty easy last time i did it so im sure its just a small detail being missed. I've slowly learned eclipse isnt able to catch every single error.
is your menu's xml file in the res/menu folder? if not it prob wont work
Yup res/menu
Here is the code for the menu from my book.
Code:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:background="@color/background"
android:layout_height="fill_parent"
android:layout_width="fill_parent"
android:padding="30dip"
android:orientation="horizontal" >
<LinearLayout
android:orientation="vertical"
android:layout_height="wrap_content"
android:layout_width="fill_parent"
android:layout_gravity="center" >
<TextView
android:text="@string/main_title"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:layout_gravity="center"
android:layout_marginBottom="25dip"
android:textSize="24.5sp" />
<Button
android:id="@+id/continue_button"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="@string/continue_label" />
<Button
android:id="@+id/new_button"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="@string/new_game_label" />
<Button
android:id="@+id/about_button"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="@string/about_label" />
<Button
android:id="@+id/exit_button"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="@string/exit_label" />
</LinearLayout>
</LinearLayout>
And the strings file
Code:
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="app_name">Sudoku</string>
<string name="main_title">Android Sudoku</string>
<string name="continue_label">Continue</string>
<string name="new_game_label">New Game</string>
<string name="about_label">About</string>
<string name="exit_label">Exit</string>
</resources>
Thats pretty close to what I'm doing, but not exactly. The main difference seems to be your using a LinearLayout & my code uses RelativeLayout. OK, I'll try your code EXACTLY when I get home later. Thanks.
When you say menu, you are referring to the options that pop up when you press the hardware menu button, right?
I ask because... what does that linearlayout code have to do with a menu?
Are you implementing this function?
onPrepareOptionsMenu(Menu menu) {
MenuItem option 1 = menu.findItem(R.id.opt1);
...
}
I thought the Layout may affect how the menu text & icons were displayed & was why I couldn't see them.
No I dont implement onPrepareOptionsMenu, only onCreateOptionsMenu and onOptionsItemSelected - I'd post my code but the forum wont let me yet
I'm following the example from Android Developers "Creating Menus" which only has those 2 methods detailed.
OK guys I've fixed it !!! You'll never guess what it was.......
.... OK, I'll tell you then
In my menu.xml, I had the menu namespace xmlns URI as https not http, I had copied & pasted this from another website. Changed it back & we are working again.
Thanks for the assist - Thanks have been awarded.
Oh man thats a killer...I've had that happen to me a couple of times already
Good example android.text instead of android:text...lol
Glad to here its working though,good luck with the rest of your app.
lol - I either need more or less caffeine - not sure which.
Thanks bud.
I'm having problems sizing an image to a button. I want it to be sized (to fill the button) dependent on whatever phone it might be run on, but the image seems to be huge on the screen an dnot even fit on the left and right sides. Below are 2 different code snipets from my main.xml, but neither work:
1st attempt...
<LinearLayout
androidrientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<ImageView android:id="@+id/ImageView01"
android:src="@drawable/grim"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:scaleType="center">
</ImageView>
</LinearLayout>
2nd attempt...
<LinearLayout
androidrientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<ImageButton
android:id="@+id/widget30"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@drawable/grim"
>
</ImageButton>
</LinearLayout>
just do a "Button" instead of an "ImageButton", you can also adjust the size of the button/image by changing the font size associated with it.
I just started to build my app's layout and I'm confused, so I could use a little help.
I want it to look like this:
- there's a bar with buttons which always stays on the bottom of the screen (like position:fixed in CSS)
- there are two (or more) lists with a dynamic number of records which will mos definitely overgrow the screen size, so I need a scrollbar on them. These will not push down the button bar.
This is easy as hell, I know, but I'm not sure how to do it properly so I won't need to change it later.
It's all about learning to love (and hate) RelativeLayout
http://blog.maxaller.name/2010/05/attaching-a-sticky-headerfooter-to-an-android-listview/
Yeah, should just be a ScrollView with a nested RelativeLayout putting your buttons on the bottom...not too painful
I have a problem with my ListView. I want it to be full size without a scrollbar (the parent of ListView is scrollable), but it shows up really short (only 1.5 rows fit in). Here's my code :
Code:
<ScrollView
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:layout_below="@id/top_controlbar"
android:layout_above="@id/bottom_controlbar">
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical">
<!-- GEOTASKS -->
<LinearLayout
android:id="@+id/geotasks_layout"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_marginTop="10dp"
>
<TextView
android:layout_width="fill_parent"
android:layout_height="30dp"
android:text="@string/main_header_geotask"
android:textSize="18sp"
android:background="@color/header_bg"
android:textColor="@color/header_text"
android:gravity="center"
android:layout_marginBottom="5dp"
/>
<ListView
android:id="@+id/list_geotasks"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
/>
<TextView
android:id="@+id/empty_geo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/main_empty_geo"
android:textSize="15sp"
android:paddingLeft="5sp"
/>
</LinearLayout>
etc, same for timed and simple tasks
I tried changing the height of the parent layout and the listLayout (all 4 combinations), but it didn't help.
Well **** my rusty sheriff's badge. I can't believe nobody knows the answer.
ScrollViews are weird. The way they stretch to fill content is not intuitive.
I can't remember the solution off the top of my head but do some googling for "ScrollView" and I think there are some answers on stackoverflow.
hth
My problem is not the scroll view, but ListView. Scrollview stretches without problems.
I want to achieve a simple thing - make the ListView display all of it's content without scrolling. How is that not possible ? OMG
At first I used LinearLayouts and added new views to the root layout. That was very ugly and I couldn't register those views for context menus. Then I found out about list views, and I couldn't be happier if I could just do this one thing.
Sorry I misunderstood what you were asking.
What's the point of having the parent of a ListView scrollable anyways? I think you're just thinking about things in a strange way and that what has got you stuck.
ListView has an addHeaderView() addFooterView() if you need static items at the top and bottom, and you know how to put bottom and top control bars using relative layout, why not eliminate the ScrollView?
I think you're making things difficult on yourself by putting something scrollable inside something scrollable.
Your other option is to use views like you were using them, they do support context menus: http://developer.android.com/reference/android/view/View.OnCreateContextMenuListener.html
Hope that helps.
Edit: btw, the reason I am recommending it this way is that even if you override ListView's onTouchEvent, I dont think it will expand to wrap all the content and be scrollable by the ScrollView. Instead it will just sit there as an unscrollable listview that leaves the user unable to reach the content beyond what they can see originally.
Hi guys, I hope that this is in the right place.
So I have been making an app for a few weeks (First one) and I had no idea that android apps was not responsive to screen size. OK not so bad. I have come from HTML CSS and PhP so that type of thing is a constant battle!
I did some digging and found out a few things, I found this sizing.
xhdpi: 720px by 1280px
large-hdpi: 640px by 960px
hdpi: 480px by 640px
mdpi: 320px by 480px
ldpi: 240px by 320px
When I first started creating the app I stuck all of the images in the mdpi folder! and well that did not work. So following the guide I rezied all of the images put them in those folders to the right size ect I also created all of the same layout folders.
layout-small
layout-large
laout-normal
layout-xlarge
not forgetting to add what was needed to the manifest
Code:
<supports-screens
android:anyDensity="true"
android:largeScreens="true"
android:normalScreens="true"
android:smallScreens="true" />
Before I did this things would move around not the images but the text would jump around on smaller or larger phone sizes looking nothing like what it does in Eclipse. So after adding all the new folder ect I loaded up the emulator and got up a small phone, and it looked great, I emailed the app to myself to test on my phone again, and things are all out of place (The text) The images are in odd shapes too.
on what I would call normal phone sizes the text is still moving around and is not going into the positions that I set them to.
I do hope this makes sense! I a little tied!
Thanks guys, hope to get this issue sorted very soon
I can't really tell what the problem is without looking at the layout XML, but off the top of the head, did you use "dp" and "sp" units to keep the sizing relative?
What kind of layout did you use? Are the positioning absolute or relative?
You could also create different layout folders, but I think that the problems are in the layout files. If you post them (or one of them), we will be able to help you better.
When I was rezing the images I was using an online image editor, I set them all into px.
Here is the layout for one of the xml files,
Code:
<?xml version="1.0" encoding="utf-8"?>
THERE WAS A LINK OR SOMETHING HERE BUT THE SITE WOULD NOT ALLOW IT, NOT SURE WHAT IT WAS!
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#000000" >
<ImageView
android:id="@+id/imageView1"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:src="@drawable/p7" />
<TextView
android:id="@+id/textView1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:text="Name"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#ffffff" />
<TextView
android:id="@+id/TextView05"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentLeft="true"
android:text="Size To Earth"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#ffffff" />
<TextView
android:id="@+id/TextView11"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentRight="true"
android:text="64"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#ffffff" />
<TextView
android:id="@+id/TextView04"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/TextView10"
android:layout_centerHorizontal="true"
android:text="Orbital Period"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#000000" />
<TextView
android:id="@+id/TextView09"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/TextView04"
android:layout_centerHorizontal="true"
android:layout_marginBottom="156dp"
android:text="8,083,079,690 km²"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#000000" />
<TextView
android:id="@+id/TextView08"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/TextView03"
android:layout_alignLeft="@+id/TextView09"
android:layout_marginBottom="86dp"
android:text="2,877,000,000 km"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#000000" />
<TextView
android:id="@+id/TextView02"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/TextView08"
android:layout_centerHorizontal="true"
android:text="Distance From The Sun"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#000000" />
<TextView
android:id="@+id/TextView03"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/TextView09"
android:layout_alignRight="@+id/TextView04"
android:text="Surface Area"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#000000" />
<TextView
android:id="@+id/TextView10"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/TextView05"
android:layout_centerHorizontal="true"
android:layout_marginBottom="93dp"
android:text="83.7 Years"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#000000" />
<TextView
android:id="@+id/TextView06"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:layout_alignParentTop="true"
android:text="Uranus"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#ffffff" />
<TextView
android:id="@+id/TextView07"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_centerVertical="true"
android:text="0d 17h 14m"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#000000" />
<TextView
android:id="@+id/TextView01"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/TextView07"
android:layout_alignRight="@+id/TextView03"
android:text="Length Of Day"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#000000" />
</RelativeLayout>
This is in the layout-normal folder.
If you need anymore of the code I will get it, there is a lot of pages though.
Thanks
Koki180 said:
When I was rezing the images I was using an online image editor, I set them all into px.
Here is the layout for one of the xml files,
Code:
<?xml version="1.0" encoding="utf-8"?>
THERE WAS A LINK OR SOMETHING HERE BUT THE SITE WOULD NOT ALLOW IT, NOT SURE WHAT IT WAS!
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#000000" >
<ImageView
android:id="@+id/imageView1"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:src="@drawable/p7" />
<TextView
android:id="@+id/textView1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:text="Name"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#ffffff" />
<TextView
android:id="@+id/TextView05"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentLeft="true"
android:text="Size To Earth"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#ffffff" />
<TextView
android:id="@+id/TextView11"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentRight="true"
android:text="64"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#ffffff" />
<TextView
android:id="@+id/TextView04"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/TextView10"
android:layout_centerHorizontal="true"
android:text="Orbital Period"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#000000" />
<TextView
android:id="@+id/TextView09"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/TextView04"
android:layout_centerHorizontal="true"
android:layout_marginBottom="156dp"
android:text="8,083,079,690 km²"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#000000" />
<TextView
android:id="@+id/TextView08"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/TextView03"
android:layout_alignLeft="@+id/TextView09"
android:layout_marginBottom="86dp"
android:text="2,877,000,000 km"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#000000" />
<TextView
android:id="@+id/TextView02"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/TextView08"
android:layout_centerHorizontal="true"
android:text="Distance From The Sun"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#000000" />
<TextView
android:id="@+id/TextView03"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/TextView09"
android:layout_alignRight="@+id/TextView04"
android:text="Surface Area"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#000000" />
<TextView
android:id="@+id/TextView10"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/TextView05"
android:layout_centerHorizontal="true"
android:layout_marginBottom="93dp"
android:text="83.7 Years"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#000000" />
<TextView
android:id="@+id/TextView06"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:layout_alignParentTop="true"
android:text="Uranus"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#ffffff" />
<TextView
android:id="@+id/TextView07"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_centerVertical="true"
android:text="0d 17h 14m"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#000000" />
<TextView
android:id="@+id/TextView01"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@+id/TextView07"
android:layout_alignRight="@+id/TextView03"
android:text="Length Of Day"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textColor="#000000" />
</RelativeLayout>
This is in the layout-normal folder.
If you need anymore of the code I will get it, there is a lot of pages though.
Thanks
Click to expand...
Click to collapse
Thank you for this.
I think that the problem are lines like these:
Code:
android:layout_above="@+id/TextView04"
android:layout_marginBottom="156dp"
You use a margin. Now, on a bigger phone, this margin is smaller. That's causing the issues.
With screenshots (one showing the layout how you want it and one how it is shown on big screens) we could help you better.
One thing for the meantime: Have a look at dimension resources. You can put these files into directories like values-large and values-small, too. (More on that: Link)
Btw, the link is the android namespace which is the same in every xml file. (For Android development you don't have to know what it is. Just don't remove it in your file. )
Wihtout the Margins ect how would the text be place into the right places? (Taking knowlage from html and css =D )
Koki180 said:
Wihtout the Margins ect how would the text be place into the right places? (Taking knowlage from html and css =D )
Click to expand...
Click to collapse
No. It wouldn't be placed right. There need to be some changes for the margings. You could define them as a dimension resource. And those can be put into /res/values-small, /res/values-large and other folders like these.
As I said above, with some screenshots we could help you better. (You can replace all texts and images if you want. )
Maybe some other layout would be better. But we can't tell you without any screenshots.