I have a html file saved in memory and this file have some images (tag ). I can't load these images because they are in the assets folder and I don't know the absolute path. What is the absolute path to assets folder? I think that with the absolute path of the images I could to load these images in my html file into my webview.
I'm basically using the same method of loading bitmaps in OpenGL that the SpriteMethodTest example uses and have been unable to get rid of an annoying outline that appears around all of my images.
For example, If I were to load an image of a white circle on a white background, I would expect to see nothing. Instead, I would see my circle because its edge would be gray. In SpriteMethodTest, I replaced the background image with white and was able to see that the edges of the android images flying around also don't seem to be rendered correctly.
Does anyone know how to load images in OpenGL without having a thin outline appear around the images?
I have a WebView on my Android application which loads (WebView.loadUrl()) different local HTML files from phone's internal storage. I would like to include some custom css styles for them, Now, I could have my app edit every HTML file and add linking reference for the CSS file.I could also read the file contents, add the CSS linking and use WebView.loadData() to load it.But is it possible to do this a lot simpler and efficiently.Note: The HTML files are downloaded from a website. So editing them manually is not possible in this case, but once downloaded they can be edited via the app if necessary.
Given the following HTML: <p>This is text and this is an image <img src="http://www.example.com/image.jpg" />.</p> Is it possible to make the image render? When using this snippet: mContentText.setText(Html.fromHtml(text));, I get a cyan box with black borders, leading me to believe that a TextView has some idea of what an img tag is.
I want to set a TextView with SpannableString which is from the method below: Html.fromHtml(String source, Html.ImageGetter imageGetter, Html.TagHandler tagHandler) But the ImageGetter here need to override the method below: public abstract Drawable getDrawable (String source) Because I need to get the drawable from the internet, I have to do it asynchronously and seems it is not.
I'm trying to load/reference images from the app's assets folder from within a HTML page in a WebView. Unlike in most of the examples the HTML page itself is not located in the assets folder but is loaded from a server via http. The background of this question are some performance improvements which should reduce the loading time (and the amount of transferred data) by loading static images directly from the device. I'm not sure if Android has some restrictions here because there's a certain possibility to exploit the app by allowing access to the local file storage from a remotely loaded webpage.
So only because I haven't taken the time to figure it out, I still have two mail apps. The gmail app and the mail widget. For some reason, when I get mail it will from time to time show up in the email app. It always shows up in gmail, but every now and then, it will also show up in the mail widget. The question I have is, why will HTML mail only show the attachments/pictures in the mail widget. The same email will not display in gmail. How can I get gmail to show HTML images?
In my android application i am trying to download images from remote server dynamically ( no of images dynamically come ). for downloading all images it is taking 30 to 40 seconds mean time user has to wait to see the activity . But it is the worst case that loading activity after loading all images. I want to load activity first then load images one by one.
I'm using Dolphin HD and I'm wondering if there's a way to load images when on wifi, and turn them off when on mobile network. I'm on a very limited data plan (20mb) but I don't want to have to turn off images every time I'm connected to wifi.
I'm on Onecosmic's ICS Port Android 4.0.3 RC2 and it happened me before on some stock ROMs. Pictures on some apps won't load, market and youtube, and HD widget won't load weather. I'm trying everything on Wifi, have connection, can download from market, play yt clips.
I am a beginner Android developer and I need to know how to Save and Load images (Bitmaps) from the Android Gallery, But I dont even know where to start! Can someone help me to know where to get started, or even look?
the question i have is simple but hard to put in words, ill give it a try anyways.i am trying to load a web page in web view,however the load time is a little high.is there anyway i can put the images in the assets folder and load them from there instead?if not, is there a way i can load the whole site from the assets folder, providing that my php files can still communicate with my internet database?i have already read most tutorials however they are pretty vague when it comes to concrete help.
How can I load an image from the web onto my phone without typing in the URL? I want to create a media application but load the cover for each song from specific locations on the web. How can I load the remote images as simple as possible? Every tutorial I try online crashes on startup.
I have heavily edited the original text and instead of the how question I am posting the code that produces the effect I wanted, namely a floating menu on top that stays fixed as I scroll whatever is in the middle with a lower menu at the bottom of the screen. Ain't life sweet - Might even work on the iPhone as well.
Why I posted was like I said in the original question. I'm fiddling with creating the initial lay out for a "mobile" application for the disabled, have tonnes of data, dictionary files, icons for the purpose etc. I want to have the app running as HTML to make it as portable as possible, i.e. make it runnable on Android, Iphone, Maemo... whatever.
I got some hints by looking at the example at http://www.quackit.com/css/codes/css_floating_menu.cfm as well as a lot of trial and error and finally minor edits by a paid freelancer.
Below you can find some crude (to put it mildly) HTML/CSS (cut the CSS part and load a style instead in the HTML's you create for cleaner code) but for now, let's look at the prototype concept.
You can see the working example on your Android device or in your Android emulator http://globability.org/webapp/aaa.html
Need to get the sound working though - but nearly there :)Links to the different web based version and thoughts behind application can be found on:
The project this application springs from can be found on [url] - Look under prototypes (it is the top one under the heading protypes).
I;ve been trying to create a custom button in android using this tutorial - http://www.gersic.com/blog.php?id=56
It works well but it doesn't say how to change the font size or weighting. Any ideas?
There was another question on here and the only answer was to use html styling but you can't change a font size in html without using css (or the deprecated font tag). There must be a better way of setting the pixel size of the font used on buttons?
I have been assigned the task to use an android tablet to run a single app in an enterprise setting. Ideally, when one switches on the tablet this app should be loaded perhaps during startup and the user need not step out of this app. The app logic itself is rather easy but I am wondering if it is at all possible to load a single app during load and not allowing the user to step out of it.
Is it possible to load a layout XML at runtime and load into activity?
In my app, I have various types of data like Person, Company, City, etc; The requirement is to dynamically load the layout, find views by tags (property names like Person.name, Person.address) and then fill in data. For example, if user has selected an object of type Company, we want to load a company.xml layout, inflate it and then associate various properties (company name, company slogan, city, address, revenue) to tagged views. One possibility I see here is - each view in the layout will be associated with property-name as tag and then appropriate data will be loaded in appropriate views.
What should be the best design you would recommend?
I'm working to convert some background images to nine patch so they scale better on different phones. The problem is that if I have the following resource structure: drawable-hdpi/background.png drawable-hdpi/button.png drawable-mdpi/background.png drawable-mdpi/button.png drawable-ldpi/background.png drawable-ldpi/button.png and then I drop a new drawable-hdpi/background.9.png file into the mix, it breaks button.png during the pre-compile. The error is "No resource found that matches the given name (at 'background' with value '@drawable/button').Simply removing that one nine patch file fixes the build. Should I be able to have some nine patch images and some normal ones, or to have nine patch only in hdpi but not mdpi or ldpi? This is Eclipse 3.5.1 with the latest ADT.