📜  如何设置长度以设置 CSS 中的列之间的间隙?

📅  最后修改于: 2021-08-30 09:55:31             🧑  作者: Mango

在本文中,我们将学习如何设置长度以设置列之间的间隙。

方法: column-gap属性用于指定将设置列之间间隙的长度。这需要一个值来修复列之间的指定间隙。

句法:

column-gap: value;

示例 1:

HTML


  

    

  

    
        
            GeeksforGeeks is my favorite site where             I can gain a lot of knowledge and can             also share my knowledge what I have gained             while learning. We can add more             paragraphs for content. This is just an             example to tell you how to specify             the optimal width for the columns in CSS?             The column width is 160px in this example.         
    
  


HTML


  

    

  

    
        
            GeeksforGeeks is my favorite site where             I can gain a lot of knowledge and can             also share my knowledge what I have             gained while learning. We can add more             paragraphs for content. This is just an             example to tell you how to specify             the optimal width for the columns in CSS?             The column width is 160px in this example.         
    
  


输出:

申请属性前:

应用属性后:

示例 2:

HTML



  

    

  

    
        
            GeeksforGeeks is my favorite site where             I can gain a lot of knowledge and can             also share my knowledge what I have             gained while learning. We can add more             paragraphs for content. This is just an             example to tell you how to specify             the optimal width for the columns in CSS?             The column width is 160px in this example.         
    
  

输出:

申请属性前:

应用属性后: