IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

Bibliothèques & Frameworks Discussion :

[AnyChart] Mettre en gras du texte


Sujet :

Bibliothèques & Frameworks

  1. #1
    Membre régulier Avatar de theocbr
    Homme Profil pro
    Étudiant
    Inscrit en
    Juin 2019
    Messages
    206
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Âge : 24
    Localisation : France, Pas de Calais (Nord Pas de Calais)

    Informations professionnelles :
    Activité : Étudiant
    Secteur : High Tech - Multimédia et Internet

    Informations forums :
    Inscription : Juin 2019
    Messages : 206
    Points : 90
    Points
    90
    Par défaut [AnyChart] Mettre en gras du texte
    Bonjour je voudrais tout simplement mettre tout les mots en gras : "pochons" "ligne 1" "ligne 2 " "lundi"....

    Nom : fsfes.PNG
Affichages : 122
Taille : 23,8 Ko

    Code html : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
     <html>
    <div id="container" ></div>
    <style type="text/css">
    html, body, #container {
        width: 90%;
        height: 80%;
        margin: 60px;
        padding: 0;
    }
    </style>
     
     </html>
     
     <script>
    anychart.onDocumentReady(function () {
     
      // data
      var data = anychart.data.set([
        ["Lundi", +resultprodLundiL1 , +resultprodLundiL2],
        ["Mardi", +resultprodMardiL1, +resultprodMardiL2],
        ["Mercredi", +resultprodMercrediL1 , +resultprodMercrediL2],
        ["Jeudi", +resultprodJeudiL1, +resultprodJeudiL2],
        ["Vendredi",  +resultprodVendrediL1 , +resultprodVendrediL2]
      ]);
     
      // map data for the each series
      var Ligne1 = data.mapAs({x: 0, value: 1});
      var Ligne2= data.mapAs({x: 0, value: 2});
     
      // chart type
      var chart = anychart.column();
     
      // set data
      var series_1 = chart.column(Ligne1);
      series_1.name("Ligne 1");
      series_1.xPointPosition(0.5);  
     
      var series_2 = chart.column(Ligne2);
      series_2.name("Ligne 2"); 
     
      series_1.fill("#3679D9");
      series_2.fill("#D93636");
      series_1.stroke("none");
      series_2.stroke("none");
     
            
            //BARRE DE SEUIL
               var yAxis = chart.yAxis();
    var marker = chart.lineMarker();
    marker.axis(yAxis);
    marker.value(350000);
    marker.stroke('red 1', 3);
    marker.zIndex(100);
      var textMarker = chart.textMarker();
    textMarker.axis(chart.yAxis());
    textMarker.value(35000);
    textMarker.align("right");
    textMarker.anchor("right-bottom");
    textMarker.fontSize(24);
    textMarker.fontColor("red");
    textMarker.offsetX(5);
    textMarker.offsetY(320)
    textMarker.text("Objectif");
     
      
      chart.yAxis().title("Pochons");
     
      // enable legend
      chart.legend(true);
     
      // switching the select mode to multi
      var interactivity = chart.interactivity();
      interactivity.selectionMode("single-select");
     
      // draw
      chart.container("container");
      chart.draw();
    });
    </script>

  2. #2
    Modérateur

    Avatar de NoSmoking
    Homme Profil pro
    Inscrit en
    Janvier 2011
    Messages
    17 119
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Isère (Rhône Alpes)

    Informations forums :
    Inscription : Janvier 2011
    Messages : 17 119
    Points : 44 954
    Points
    44 954
    Par défaut
    Bonjour,
    il faut utiliser la méthode fontWeight() sur tes différents éléments.

    Par exemple
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    chart.title('Conditionnement');
    chart.title()
      .padding([0, 0, 5, 0])
      .fontWeight("bold");
     
    chart.legend()
      .enabled(true)
      .fontWeight("bold")
      .fontSize("1em")
      .padding([0, 0, 20, 0]);
     
    chart.xAxis().title("Titre axe X");
    chart.xAxis()
      .title()
        .fontWeight("bold")
        .fontSize("1em")
        .fontColor("#F00")
     
    chart.yAxis().title("Titre axe Y")
    chart.yAxis()
      .title()
        .fontWeight("bold")

  3. #3
    Membre régulier Avatar de theocbr
    Homme Profil pro
    Étudiant
    Inscrit en
    Juin 2019
    Messages
    206
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Âge : 24
    Localisation : France, Pas de Calais (Nord Pas de Calais)

    Informations professionnelles :
    Activité : Étudiant
    Secteur : High Tech - Multimédia et Internet

    Informations forums :
    Inscription : Juin 2019
    Messages : 206
    Points : 90
    Points
    90
    Par défaut
    Merci beaucoup pour ton aide

+ Répondre à la discussion
Cette discussion est résolue.

Discussions similaires

  1. Mettre en gras du texte dans un MSGBOX
    Par gantec dans le forum Général VBA
    Réponses: 20
    Dernier message: 21/09/2013, 20h52
  2. Réponses: 8
    Dernier message: 02/02/2009, 14h11
  3. Mettre en gras le texte d'un input
    Par musicann dans le forum Balisage (X)HTML et validation W3C
    Réponses: 5
    Dernier message: 16/05/2007, 11h44
  4. Mettre en gras un texte placé après un signet word
    Par dederfred dans le forum Delphi
    Réponses: 2
    Dernier message: 29/11/2006, 14h31
  5. Couleur mettre en gras le text d un JTextArea
    Par jean_bobi dans le forum Composants
    Réponses: 4
    Dernier message: 01/11/2005, 12h28

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo