Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to change Text's fontWeight #51564

Closed
agordeev opened this issue Feb 27, 2020 · 3 comments
Closed

Unable to change Text's fontWeight #51564

agordeev opened this issue Feb 27, 2020 · 3 comments
Labels
waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds

Comments

@agordeev
Copy link
Contributor

I cannot update Text's fontWeight: setting it does nothing.

Steps to Reproduce

  1. Run flutter create bug.
  2. Update main.dart as follows:
import 'package:flutter/material.dart';

void main() => runApp(MyApp());

class MyApp extends StatelessWidget {
  // This widget is the root of your application.
  @override
  Widget build(BuildContext context) {
    final theme = ThemeData(primarySwatch: Colors.blue);
    return MaterialApp(
      title: 'Flutter Demo',
      theme: theme,
      home: MyHomePage(title: 'Flutter Demo Home Page'),
    );
  }
}

class MyHomePage extends StatefulWidget {
  MyHomePage({Key key, this.title}) : super(key: key);
  final String title;

  @override
  _MyHomePageState createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text(widget.title),
      ),
      body: Center(
        child: Column(
          mainAxisAlignment: MainAxisAlignment.center,
          children: <Widget>[
            Text(
              'You have pushed the button this many times:',
              style: Theme.of(context)
                  .textTheme
                  .headline6
                  .copyWith(fontWeight: FontWeight.w700),
            ),
          ],
        ),
      ),
    );
  }
}
  1. See the text is not bold.

I'm using version 1.15.3

@VladyslavBondarenko
Copy link

Hi @agordeev
Are you experiencing this with iOS?
checked and it's working for Android

probably related to #49492

@VladyslavBondarenko VladyslavBondarenko added the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label Feb 27, 2020
@dnfield
Copy link
Contributor

dnfield commented Feb 27, 2020

This is almost certainly a duplicate of #49492 - please comment here if you are not using iOS and we will reopen.

@dnfield dnfield closed this as completed Feb 27, 2020
@github-actions
Copy link

This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 22, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds
Projects
None yet
Development

No branches or pull requests

3 participants