试题一layout和配置
来源:互联网 发布:淘宝818开学季 商城 编辑:程序博客网 时间:2024/05/20 03:45
/******************************************************************/activity_main.xml
<?xml version="1.0" encoding="utf-8"?><LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical" tools:context="com.example.yuekao.MainActivity"> <android.support.design.widget.TabLayout android:id="@+id/tablayout" android:layout_width="match_parent" android:layout_height="50dp" app:tabMode="scrollable" app:tabSelectedTextColor="#ff0000" ></android.support.design.widget.TabLayout> <android.support.v4.view.ViewPager android:id="@+id/viewpager" android:layout_width="match_parent" android:layout_height="match_parent"></android.support.v4.view.ViewPager></LinearLayout>
/*******************************************************************/item.xml
<?xml version="1.0" encoding="utf-8"?><LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical" > <LinearLayout android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical"> <TextView android:id="@+id/textitem" android:layout_width="match_parent" android:layout_height="wrap_content" /> <ImageView android:id="@+id/imageitem" android:layout_width="match_parent" android:layout_height="100dp" android:scaleType="fitXY" /> </LinearLayout></LinearLayout>
/**************************************************************/mfragmnet.xml
<?xml version="1.0" encoding="utf-8"?><LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical"> <com.limxing.xlistview.view.XListView android:id="@+id/xlistview" android:layout_width="match_parent" android:layout_height="wrap_content"></com.limxing.xlistview.view.XListView></LinearLayout>
/******************************************************************/secondactivity.xml
<?xml version="1.0" encoding="utf-8"?><LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical"> <TextView android:id="@+id/tv1" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="zmkjnfvjdfnvjdfvldf" /> <com.github.chrisbanes.photoview.PhotoView android:id="@+id/iv1" android:layout_width="match_parent" android:layout_height="match_parent" /></LinearLayout>
/***********************************************************/配置
<?xml version="1.0" encoding="utf-8"?><manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.example.yuekao"> <uses-permission android:name="android.permission.INTERNET" /> <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" /> <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" /> <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" /> <application android:name=".App" android:allowBackup="true" android:icon="@mipmap/ic_launcher" android:label="@string/app_name" android:roundIcon="@mipmap/ic_launcher_round" android:supportsRtl="true" android:theme="@style/AppTheme"> <activity android:name=".MainActivity"> <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> </activity> <activity android:name=".SecondActivity" /> </application></manifest>
阅读全文
0 0
- 试题一layout和配置
- Android Common Layout 和 Adapter Layout 简单介绍(及ListView的简单使用)(一)
- ZendFramework2学习笔记 静态配置layout模板和动态设置layout模板
- Layout---Linear Layout和Relative Layout
- Android各种Layout特性和使用汇总(一)
- 初识iOS layout(一)
- key layout 配置
- Java面试题和解答(一)
- 栈和队列面试题(一)
- eclipse布局的layout和layout data
- QT 中Vertical Layout 和 Horizontal Layout
- layout、layout-land和layout-port的区别
- layout、layout-land和layout-port的区别
- layout、layout-land和layout-port的区别
- Layout 和 Menu【转】
- View和Layout
- layout和measure
- onMeasure和childview.layout
- Android edittext键盘的隐藏和显示
- Java基础
- 输出数组中奇数次出现的数
- Method breakpoints may dramatically slow down debugging
- JQuery中操作Css样式的方法
- 试题一layout和配置
- 将博客搬至CSDN
- Intel, AMD及VIA CPU的微架构(2)
- 恶意代码分析实战 Lab 1-2 习题笔记
- 620. Not Boring Movies
- Linux学习总结(七)
- ajax 和 php 和 javascript(html)
- 变量的默认初始化、struct结构体提醒
- Tomcat6项目移到Tomcat7 提示 404 解决方案