所以我对android开发很新,我只是无法在动作栏中显示任何图标.
我使用最小sdk API 15创建一个新项目,并在Theme-Dropdown(XML-Design-View)中选择"Holo.Light".
所以我希望它看起来像这样:http: //i.stack.imgur.com/zfgCq.png
但它看起来像这样:http: //i.imgur.com/Lmxutct.png
我的AndroidManifest.xml:
<?xml version="1.0" encoding="utf-8"?>
Run Code Online (Sandbox Code Playgroud)
<application
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:theme="@style/AppTheme" >
<activity
android:name=".MainActivity"
android:label="@string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
Run Code Online (Sandbox Code Playgroud)
我想我必须以某种方式将android:theme更改为Holo.Light?但是没有ressource定义,我似乎无法添加任何..
我的styles.xml:
<resources>
<!-- Base application theme. -->
<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar"/>
<!-- Customize your theme here. -->
Run Code Online (Sandbox Code Playgroud)
ic_launcher.png位于drawables文件夹中..所以我该怎么办才能显示该死的图标?
(我使用我的HTC一个M8顺便说一句,但它也不会出现在模拟器上)
谢谢!
我正在尝试创建一个1页的滚动布局:http: //codepen.io/TimRos/pen/vOXVQM
每个"页面"都是这样构建的:
section {
display: flex;
min-height: 100vh;
flex-direction: column;
}
Run Code Online (Sandbox Code Playgroud)
现在,我希望能够通过单击位于该部分底部的锚点来滚动到不同的部分.这在#home部分工作正常:
<a data-scroll href="#gallery"><span class="arrow">∨</span></a>
Run Code Online (Sandbox Code Playgroud)
CSS:
.arrow {
position: absolute;
bottom: 0;
width: 60px;
font-size: 3em;
color: #e3e3e3;
background: #3f3f3f;
}
Run Code Online (Sandbox Code Playgroud)
当我在每个部分放置完全相同的锚点时,只要我给它一个位置:绝对; 和底部:0; 归因于它位于#home部分的底部,但我希望它坚持其父容器的底部.
页脚也存在同样的问题,绝对定位会粘在第一部分的底部,而不是它的父部分.
出了什么问题?