tabs

Custom TabWidget Android Tab Indicator

旧时模样 提交于 2019-12-22 17:39:06
问题 Okay, so i am making an android app that has tabs, now my problem is that the tab widget isn't uniform across the diffrent android versions or devices. I want to make it to be the same on any android this is my tab activity import android.app.TabActivity; import android.content.Intent; import android.os.Bundle; import android.widget.TabHost; import android.widget.TabHost.TabSpec; public class Cook extends TabActivity { /** Called when the activity is first created. */ @Override public void

Justified tabs in Foundation for Apps project

有些话、适合烂在心里 提交于 2019-12-22 17:05:26
问题 I'm looking for a way to achieve full-width/justified tabs in a container in my Foundation app. This is what's happening currently. In Twitter Bootstrap I can do this and I'm looking for the same type of functionality in Foundation. Is it possible natively? I'm just using the default tabs structure example right now. 回答1: Tabs in Foundation use the flexbox model. By default, their flex-grow is 0 (they don't grow to fill up the parent). Change it to 1 and they will. Optionally, you might want

javascript. Can't open new tab in safari

我与影子孤独终老i 提交于 2019-12-22 14:04:13
问题 The following javascript opens a new tab fine in Firefox, chrome, and IE. but it opens a new window in safari. javascript:window.open(url,'_blank'); // opens new window in safari. I need to open a new tab NOT a new window in safari. anyone else seeing this behavior? fixes? I can't seem to find any recent posts that address this... maybe it's just me. -Thanks. Using safari 5.1.7 on windows. 回答1: It turns out it's a browser preference, which can be edited under Edit -> Preferences -> Tabs and

android custom font for tabs

守給你的承諾、 提交于 2019-12-22 11:28:41
问题 I would like to have a custom font for my tabs. Here's what I have tried: <style name="CustomTabWidgetText" parent="@android:style/TextAppearance.Widget.TabWidget"> <item name="android:textSize">14sp</item> <item name="android:typeface">@assets/fonts/heartbre</item> <item name="android:textStyle">bold</item> </style> But I got an error in <item name="android:typeface">@assets/fonts/heartbre</item> . Has anybody here tried customizing the font of tabs? 回答1: The only (currently) available way

How to get Chrome to open multiple sites in a new tab

拥有回忆 提交于 2019-12-22 10:46:36
问题 I'm developing a tool that lets you open multiple pages at once with a shortcut, to be used for things like opening your daily sites or querying multiple search engines for a phrase. In Firefox, Internet Explorer and Opera, assuming you've unblocked pop-ups for the domain, the code works as expected. Chrome, however, opens the sites in new windows instead of tabs if the links are opened automatically when the page loads. If openAll() is commented out and the button is clicked or a key is

load different activities in tabs

眉间皱痕 提交于 2019-12-22 09:38:41
问题 It took quite a while searching stackoverflow and google and can not find a guide to properly explain to me how to implement Tabs in my application. I know it should not be used TabActivity, I also read about the recommendation not to use TabHost (at least that understanding). My interest is not just changing the content is run a full activity when changing tab. Example MainActivity: - Tab1Activity - Tab2Activity - Tab3Activity My goal is to build an application that is supported by a wide

How to trigger an event after hitting Tab key in textbox

喜夏-厌秋 提交于 2019-12-22 08:44:39
问题 I want to trigger an event like displaying an alert message when I hit the Tab key inside a textbox. <input type="text" /> $("input").blur(function (e) { if (e.which == 9) alert("Hurray!!!"); }); What I want to happen is that whenever I type inside a textbox then hit Tab it will do something. Im using jquery1.7.2.min.js I really don't know if Im doing it right. For the demo http://jsfiddle.net/QfCpC/ 回答1: $("input").keydown(function (e) { if (e.which == 9) alert("Hurray!!!"); }); Fiddle Demo

AngularJS Material Design : Different colors for different tabs in md-tabs

青春壹個敷衍的年華 提交于 2019-12-22 08:18:32
问题 Is there a way to set different background colors for different tabs in md-tabs ? The default is no color as can be seen in tabs demo I tried <md-tabs background-color="green"> but it's not working 回答1: AngularJS Material design (md) tabs, md-tabs background color is transparent and uses the background color of your main container. Try to add CSS class for md-tabs . Added background to entire md-tabs md-tabs { background: red; border: 1px solid #e1e1e1; } By adding CSS childs to md-tab class,

click listener for tab panel in EXTJS

这一生的挚爱 提交于 2019-12-22 08:14:32
问题 i use a tab panel in extjs. I want to display an alert when clicked on a tab. But i am not sure how. This is what i do now: { xtype: 'tabpanel', activeTab: 0, region: 'center', items: [ { xtype: 'panel', title: 'All', items: [grid] }, { xtype: 'panel', title: 'Closed' }, { xtype: 'panel', title: 'Open' } ], listeners: { click: function () { alert('test'); } } } How can is display All, Closed or Open when there is clicked on that tab? 回答1: There is no event for tab click in TabPanel , however

Reload page with different anchor

不羁岁月 提交于 2019-12-22 07:09:01
问题 Just got stuck with one problem. I have a page with Jquery UI tabs. Each tab can be accessed from different page by adding a hash tag to the link and it loads the page with the tab that I need. However, I also need to access different tabs within the same page. What I came up with is to add target="_parent" to the link with hash tag: <a href="pictures.htm#tab2" target="_parent"> and it does what I need but only in IE. It reloads the page with different hash tag but for some reason Chrome and